Write a program to find the given number is odd or even
without using any loops(if,for,do,while)

Answer Posted / kiran

main()
{
int n;
printf("enter the number");
scanf("%d",&n);
n%2==0?(printf("given number is even");):(printf("given
number is odd"););

Is This Answer Correct ?    8 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Write a code to generate a series where the next element is the sum of last k terms.

721


Explain modulus operator. What are the restrictions of a modulus operator?

593


pgm to find any error in linklist(in single linklist check whether any node points any of previous nodes instead of next node)

2193


What is openmp in c?

602


What is the use of #include in c?

568






What is assignment operator?

618


What is c++ used for today?

649


What is use of integral promotions in c?

654


What is p in text message?

528


What is the difference between the = symbol and == symbol?

615


A variable that is defined in a specified portion of a program but can be used throughout the program a) global variable b) local variable c) character d) none

718


Write a program to print fibonacci series using recursion?

577


Write a client and server program in C language using UDP, where client program interact with the Server as given below: i) The client begins by sending a request to send a string of 8 characters or series of 7 numbers, the server sends back a characters or numbers as per the request of the client. ii) In case of series of 7 numbers: The client sends a multiplication of numbers, to the server. iii) In case of a string of 8 characters: The client sends a reverse order of string to the server.. iv) Server will send an acknowledgment to the client after receiving the correct answer

3829


What are identifiers in c?

622


Explain high-order bytes.

668