/* Copyright (c) 2001-2009 by SoftIntegration, Inc. All Rights Reserved */
/* itoa example */
#include <stdio.h>
#include <stdlib.h>

int main ()
{
    int i;
    char buffer [33];
    printf ("Enter a number: ");
    scanf ("%d", &i);
    itoa (i, buffer, 10);
    printf ("decimal: %s\n", buffer);
    itoa (i, buffer, 16);
    printf ("hexadecimal: %s\n", buffer);
//    itoa (i, buffer, 2);
//    printf ("binary: %s\n", buffer);
    return 0;
}

/*
Output:
Enter a number: 1750
decimal: 1750
hexadecimal: 6d6
//binary: 11011010110
*/

