Write a small C program to determine whether a machine's
type is little-endian or big-endian.
Answer Posted / vasundhara
int main()
{
int x=1;
if(*(char*)&x)
printf("little endian");
else
printf("big endian");
return 0;
}
| Is This Answer Correct ? | 7 Yes | 1 No |
Post New Answer View All Answers
using only #include
Write the Program to reverse a string using pointers.
How do you determine the length of a string value that was stored in a variable?
What is equivalent to ++i+++j?
How do I copy files?
What is "Duff's Device"?
int main() { Int n=20,i; For(i=0;i<=n;i--) { Printf(“-“); Return 0;
What is the method to save data in stack data structure type?
How can I change the size of the dynamically allocated array?
hi send me sample aptitude papers of cts?
Q.1 write aprogram to stack using linklist o insert 40 items? Q.2 write a program to implement circular queue with help of linklist?
What is formal argument?
What is an lvalue?
What does the error 'Null Pointer Assignment' mean and what causes this error?
Process by which one bit pattern in to another by bit wise operation is?