write a program for odd numbers?

Answer Posted / narendra

#include<stdio.h>
#include<conio.h>
void main()
{
int num;
clrscr();
printf("enter ur range:");
scanf("%d",&num);
for(i=1;i<=num;i+2)
printf("%d",num);
getch();
}

Is This Answer Correct ?    27 Yes 19 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why doesnt the call scanf work?

676


When do you not use the keyword 'return' when defining a function a) Always b) Never c) When the function returns void d) dfd

643


write a c program to find the largest and 2nd largest numbers from the given n numbers without using arrays

1787


Describe how arrays can be passed to a user defined function

785


Is there sort function in c?

579






What is static memory allocation? Explain

633


Explain the difference between exit() and _exit() function?

637


Is a house a shell structure?

698


How to write a program for machine which is connected with server for that server automatically wants to catch the time for user of that machine?

1592


int i=10; printf("%d %d %d", i, i=20, i);

1017


What is the Purpose of 'extern' keyword in a function declaration?

655


Explain what are the different file extensions involved when programming in c?

635


In c programming write a program that will print 10 multiples of 3 except 15,18,21 using looping

980


Why is c called a structured programming language?

681


Differentiate between a for loop and a while loop? What are it uses?

676