#include <stdio.h>

/********************************
 * Examples of converting numbers
 * between signed and unsigned
 *
 * Author: Sarah Heckman, NCSU
 *******************************/
int main(void) 
{

   int a;
   unsigned b;
   a = -36;
   b = (unsigned) a;
   a = (int) b;

   printf("b = %u\na = %d\n", b, a);

   int c;
   unsigned short d;
   c = -36;
   d = (unsigned short) c;
   c = (int) d;

   printf("d = %u\nc = %d\n", d, c);

   return 0;

}
