<?xml version="1.0" encoding="utf-8"?>
<!-- generator="FeedCreator 1.7.2-ppt DokuWiki" -->
<?xml-stylesheet href="http://www.intma.in/wiki/lib/exe/css.php?s=feed" type="text/css"?>
<rdf:RDF
    xmlns="http://purl.org/rss/1.0/"
    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
    xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
    xmlns:dc="http://purl.org/dc/elements/1.1/">
    <channel rdf:about="http://www.intma.in/wiki/feed.php">
        <title>intma.in</title>
        <description></description>
        <link>http://www.intma.in/wiki/</link>
        <image rdf:resource="http://www.intma.in/wiki/lib/images/favicon.ico" />
       <dc:date>2010-09-08T15:45:28-04:00</dc:date>
        <items>
            <rdf:Seq>
                <rdf:li rdf:resource="http://www.intma.in/wiki/bmp?rev=1266183426&amp;do=diff"/>
                <rdf:li rdf:resource="http://www.intma.in/wiki/d2b?rev=1255664999&amp;do=diff"/>
                <rdf:li rdf:resource="http://www.intma.in/wiki/huffman_coding?rev=1254810286&amp;do=diff"/>
                <rdf:li rdf:resource="http://www.intma.in/wiki/linked_lists?rev=1261237115&amp;do=diff"/>
                <rdf:li rdf:resource="http://www.intma.in/wiki/morse?rev=1263069828&amp;do=diff"/>
                <rdf:li rdf:resource="http://www.intma.in/wiki/palindrome?rev=1260768380&amp;do=diff"/>
                <rdf:li rdf:resource="http://www.intma.in/wiki/pointers?rev=1260938243&amp;do=diff"/>
                <rdf:li rdf:resource="http://www.intma.in/wiki/raw?rev=1260767755&amp;do=diff"/>
                <rdf:li rdf:resource="http://www.intma.in/wiki/server_level?rev=1266189365&amp;do=diff"/>
                <rdf:li rdf:resource="http://www.intma.in/wiki/sieve_eratosthenes?rev=1265914472&amp;do=diff"/>
                <rdf:li rdf:resource="http://www.intma.in/wiki/start?rev=1278947605&amp;do=diff"/>
                <rdf:li rdf:resource="http://www.intma.in/wiki/strtol?rev=1263069829&amp;do=diff"/>
                <rdf:li rdf:resource="http://www.intma.in/wiki/tornado?rev=1257533005&amp;do=diff"/>
            </rdf:Seq>
        </items>
    </channel>
    <image rdf:about="http://www.intma.in/wiki/lib/images/favicon.ico">
        <title>intma.in</title>
        <link>http://www.intma.in/wiki/</link>
        <url>http://www.intma.in/wiki/lib/images/favicon.ico</url>
    </image>
    <item rdf:about="http://www.intma.in/wiki/bmp?rev=1266183426&amp;do=diff">
        <dc:format>text/html</dc:format>
        <dc:date>2010-02-14T16:37:06-04:00</dc:date>
        <title>bmp</title>
        <link>http://www.intma.in/wiki/bmp?rev=1266183426&amp;do=diff</link>
        <description>Answer To:&lt;http://forum.codecall.net/c-c/23108-need-do-some-simple-image-analysis.html#post225689&gt;

It's highly recommend you read the last part of the wikipedia article on the BMP file format (or all of it) to learn how to extract pixel information.</description>
    </item>
    <item rdf:about="http://www.intma.in/wiki/d2b?rev=1255664999&amp;do=diff">
        <dc:format>text/html</dc:format>
        <dc:date>2009-10-15T23:49:59-04:00</dc:date>
        <title>d2b</title>
        <link>http://www.intma.in/wiki/d2b?rev=1255664999&amp;do=diff</link>
        <description>The easiest and most straightforward approach to converting from decimal to binary is using a stack, dividing the number by two until its equal to zero and storing the remainder.

C


#include &lt;stdio.h&gt;
#include &lt;stdlib.h&gt;

typedef struct stack_node
{
    signed char         value;
    struct stack_node   *prev;
} stack_node_t;

void stack_push(stack_node_t **node, signed char value)
{
    stack_node_t *temp = NULL;
    
    temp = (stack_node_t*)malloc(sizeof(stack_node_t));
    temp-&gt;value = v…</description>
    </item>
    <item rdf:about="http://www.intma.in/wiki/huffman_coding?rev=1254810286&amp;do=diff">
        <dc:format>text/html</dc:format>
        <dc:date>2009-10-06T02:24:46-04:00</dc:date>
        <title>huffman_coding</title>
        <link>http://www.intma.in/wiki/huffman_coding?rev=1254810286&amp;do=diff</link>
        <description>I'm not going to bother with a large prelude or a massive amount of theory; read the wikipedia article. Instead I'm going to cover the basics and just enough to get a working implementation in C.

Frequency-sorted binary tree


A binary tree is simply a tree where each node has at most two children, 0 or 1.</description>
    </item>
    <item rdf:about="http://www.intma.in/wiki/linked_lists?rev=1261237115&amp;do=diff">
        <dc:format>text/html</dc:format>
        <dc:date>2009-12-19T10:38:35-04:00</dc:date>
        <title>linked_lists</title>
        <link>http://www.intma.in/wiki/linked_lists?rev=1261237115&amp;do=diff</link>
        <description>Linked lists are one of the most basic data structures you'll ever encounter in computer programming. Its often the base for many other common structures, like queues and stacks.

Linked lists (of varying type) can come in two forms, linear, like so:</description>
    </item>
    <item rdf:about="http://www.intma.in/wiki/morse?rev=1263069828&amp;do=diff">
        <dc:format>text/html</dc:format>
        <dc:date>2010-01-09T15:43:48-04:00</dc:date>
        <title>morse</title>
        <link>http://www.intma.in/wiki/morse?rev=1263069828&amp;do=diff</link>
        <description>Answer To: &lt;http://forum.codecall.net/c-c/23032-recursion-binarytree-morsecode.html&gt;

This is a very nasty example, and I blame it on the time (3:19 AM). Try handing this in your teacher will laugh at you. You'll probably want to extend the table as well, I've only done a-z.</description>
    </item>
    <item rdf:about="http://www.intma.in/wiki/palindrome?rev=1260768380&amp;do=diff">
        <dc:format>text/html</dc:format>
        <dc:date>2009-12-14T00:26:20-04:00</dc:date>
        <title>palindrome</title>
        <link>http://www.intma.in/wiki/palindrome?rev=1260768380&amp;do=diff</link>
        <description>Answer to: &lt;http://forum.codecall.net/c-c/22050-palindrome-anyone.html&gt;

Determining if a string is a palindrome is a common beginner computer sciences question. For some reason, the majority of the answers I see involve creating a reversed copy of the string and comparing them. A faster, straightforward approach is to use two pointers, one from the head (or beginning) of the string and another from the tail (or end) of the string.</description>
    </item>
    <item rdf:about="http://www.intma.in/wiki/pointers?rev=1260938243&amp;do=diff">
        <dc:format>text/html</dc:format>
        <dc:date>2009-12-15T23:37:23-04:00</dc:date>
        <title>pointers</title>
        <link>http://www.intma.in/wiki/pointers?rev=1260938243&amp;do=diff</link>
        <description>If you are new to C or C++ programming, you may be perplexed by your first encounter with a pointer. What is it good for, how do I use them in my own programs, and what do they actually do? These things aren't always easy to understand, but this tutorial will shed some light on the subject.</description>
    </item>
    <item rdf:about="http://www.intma.in/wiki/raw?rev=1260767755&amp;do=diff">
        <dc:format>text/html</dc:format>
        <dc:date>2009-12-14T00:15:55-04:00</dc:date>
        <title>raw</title>
        <link>http://www.intma.in/wiki/raw?rev=1260767755&amp;do=diff</link>
        <description>Answer To: [23:49:44] &lt;john&gt; in c, is it possible to read character by character rather than line by line?

:!: Everything described here only applies to unix's (OS X, Linux, Solaris, ect...) For Windows see ReadConsoleInput() on MSDN.

Often, when one is making a console application you don't want to wait for [enter] to get input; rather, you want to get each and every character as its typed. The default mode (called canonical mode) sees input as lines - it will wait to act until the line is fi…</description>
    </item>
    <item rdf:about="http://www.intma.in/wiki/server_level?rev=1266189365&amp;do=diff">
        <dc:format>text/html</dc:format>
        <dc:date>2010-02-14T18:16:05-04:00</dc:date>
        <title>server_level</title>
        <link>http://www.intma.in/wiki/server_level?rev=1266189365&amp;do=diff</link>
        <description>:!: Warning: Minecraft is an alpha product, ever changing and ever improving. I've given up trying to keep up, and will only update this page again after its finally released.

Maps for MineCraft are stored in a file called server_level.dat within the main server directory. 
The format of the file varies, but all versions (so far) follow the same layout.</description>
    </item>
    <item rdf:about="http://www.intma.in/wiki/sieve_eratosthenes?rev=1265914472&amp;do=diff">
        <dc:format>text/html</dc:format>
        <dc:date>2010-02-11T13:54:32-04:00</dc:date>
        <title>sieve_eratosthenes</title>
        <link>http://www.intma.in/wiki/sieve_eratosthenes?rev=1265914472&amp;do=diff</link>
        <description>A simple implementation of the Sieve of Eratosthenes, a simple, ancient algorithm for finding all prime numbers up to a specified integer. More information can be found on wikipedia, here.

We use a bit array to efficiently store the state of each number. If a number is 0, its a prime. If a number is 1, it isn't. Simple, no? As an example, after the sieve runs, prime[0] will look like this:</description>
    </item>
    <item rdf:about="http://www.intma.in/wiki/start?rev=1278947605&amp;do=diff">
        <dc:format>text/html</dc:format>
        <dc:date>2010-07-12T11:13:25-04:00</dc:date>
        <title>start</title>
        <link>http://www.intma.in/wiki/start?rev=1278947605&amp;do=diff</link>
        <description>This site is still under construction by a team of secret mad scientists. LOL

You can usually find them in their evil lair: irc.podnet.org:6667 #intmain.

The intma.in forum is here.

	*  Pointers (C,CPP)
	*  Function Pointers (CPP)
	*  Directory Access (C)
	*  Basic Process Creation and Communication (C)</description>
    </item>
    <item rdf:about="http://www.intma.in/wiki/strtol?rev=1263069829&amp;do=diff">
        <dc:format>text/html</dc:format>
        <dc:date>2010-01-09T15:43:49-04:00</dc:date>
        <title>strtol</title>
        <link>http://www.intma.in/wiki/strtol?rev=1263069829&amp;do=diff</link>
        <description>Answer To: &lt;http://forum.codecall.net/c-c/22551-question-about-arrays-counters.html&gt;


#include &lt;stdio.h&gt;
#include &lt;stdlib.h&gt;

int main(const int argc, const char* argv[]){
    int     i;
    char    *ep;
    for(i = 1; i &lt; argc; i++){
        if(!strtol(argv[i],&amp;ep,10)){
            printf(&quot;Error %s.\n&quot;,argv[i]);
        }else{
            printf(&quot;Integer %s.\n&quot;,argv[i]);
        }
    }
}</description>
    </item>
    <item rdf:about="http://www.intma.in/wiki/tornado?rev=1257533005&amp;do=diff">
        <dc:format>text/html</dc:format>
        <dc:date>2009-11-06T13:43:25-04:00</dc:date>
        <title>tornado</title>
        <link>http://www.intma.in/wiki/tornado?rev=1257533005&amp;do=diff</link>
        <description>Answer To: &lt;http://forum.codecall.net/c-c/22309-sorting-problem.html&gt;


/* Example program for http://forum.codecall.net/c-c/22309-sorting-problem.html */

#include &lt;stdio.h&gt;
#include &lt;stdlib.h&gt;
#include &lt;string.h&gt;

typedef struct ef
{
    unsigned int year;
    int ef[6];
} ef_t;

int main(int argc, const char **argv)
{
    /*
        This is called a conditional expression. Re-written, it would be:
        if(argc &gt; 1)
            fname_t = argv[1];
        else
            fname_t = &quot;t-scale.…</description>
    </item>
</rdf:RDF>
