Answer Posted / mehak saini
include<stdio.h>
include<conio.h>
void main()
{
inti,num;
printf("enter the number")
scanf(%d",&num);
for(i=1;i=<num;i+1)
{
if(i%2==0)
{
printf("%d",i);
}
}
getch();
}
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
write a program to find the given number is prime or not
What is the difference between declaring a variable and defining a variable?
What are the header files used in c language?
What are near, far and huge pointers?
What is structure in c language?
The program will first compute the tax you owe based on your income. User is prompted to enter income. Program will compute the total amount of tax owed based on the following: Income Tax 0 - $45,000 = 0.15 x income $45,001 - $90,000 = 6750 + 0.20 x (income – 45000) $90,001 - $140,000 = 15750 + 0.26 x (income – 90000) $140,001 - $200,000 = 28750 + 0.29 x (income – 140000) Greater than $200,000 = 46150 + 0.33 x (income – 200000) Dollar amounts should be in dollars and cents (float point numbers with two decimals shown). Tax is displayed on the screen.
Discuss the function of conditional operator, size of operator and comma operator with examples.
What are the types of unary operators?
Do pointers take up memory?
What is the use of #define preprocessor in c?
Explain which of the following operators is incorrect and why? ( >=, <=, <>, ==)
Can a program have two main functions?
Explain why c is faster than c++?
Explain what is meant by high-order and low-order bytes?
When do we get logical errors?