find a number whether it is even or odd without using any
control structures and relational operators?
Answer Posted / guest
#include<stdio.h>
#include<conio.h>
void main()
{
int x;
if(x%2==0)
printf("even");
else
printf("odd");
getch();
}
| Is This Answer Correct ? | 4 Yes | 25 No |
Post New Answer View All Answers
Devise a program that inputs a 3 digit number n and finds out whether the number is prime or not. Find out its factors.
FILE PROGRAMMING
Write a function stroverlap that takes (at least) two strings, and concatenates them, but does not duplicate any overlap. You only need to worry about overlaps between the end of the first string and the beginning of the second string. Examples: batman, manonthemoon = batmanonthemoon batmmamaman, mamamanonthemoon = batmmamamanonthemoon bat, man = batman batman, batman = batman batman, menonthemoon = batmanmenonthemoon
What are pointers? Why are they used?
Is multithreading possible in c?
What is typedef?
Is it possible to have a function as a parameter in another function?
What are linked lists in c?
Explain high-order bytes.
What is the use of a semicolon (;) at the end of every program statement?
How do c compilers work?
Is fortran faster than c?
Explain what are binary trees?
What are logical errors and how does it differ from syntax errors?
What is use of bit field?