Daily One Algorithm
A blog dedicated to those who live, drink and eat Algorithms.
Wednesday, July 26, 2006
Little / Big Endian
/***
A program to find if a machine is big or little endian.
***/
#include
main()
{
int i = 1;
char *p= (char *)&i;
if(*p == 1)
printf("Little");
else
printf("Big");
printf(" Endian\n");
}
1 comment:
Anonymous said...
Cool man!
Friday, September 04, 2009
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
1 comment:
Cool man!
Post a Comment