To find whether a number is even or odd without using any
conditional operator??
Answer Posted / naveen
main ()
{
int num;
if ( num & 1 )
printf ("num is odd number\n");
else
printf ("num is even number\n");
}
Is This Answer Correct ? | 21 Yes | 13 No |
Post New Answer View All Answers
FILE PROGRAMMING
Why calloc is better than malloc?
Hi can anyone tell what is a start up code?
What are the advantages of c preprocessor?
How to write a code for implementing my own printf() and
scanf().... Please hep me in this... I need a guidance...
Can you give an coding for c... Please also explain about
the header files used other than #include
Why c is called a mid level programming language?
Is there a built-in function in C that can be used for sorting data?
How many levels of pointers can you have?
Write a program in "C" to calculate the root of a quadratic equation ax^2+bx+c=0, where the value of a,b & c are known.
What is structure of c program?
What are the string functions? List some string functions available in c.
write a program to display all prime numbers
Are there constructors in c?
What is the advantage of a random access file?
Is there any algorithm to search a string in link list in the minimum time?(please do not suggest the usual method of traversing the link list)