write a c program that prints all multiples of 3between 1
and 50.
Answers were Sorted based on User's Feedback
Answer / yamuna
/*A.Yamuna III BSc CS L.R.G. COLLEGE,TIRUPUR*/
#include<stdio.h>
#include<conio.h>
void main()
{
int a;
printf("The multiples of 3 between 1 and 50 are :");
for(a=1;a<=50;a++)
{
if(a%3==0)
{
printf("\n%d",a);
}
}
getch();
}
| Is This Answer Correct ? | 47 Yes | 6 No |
Answer / dj
#include<stdio.h>
#include<conio.h>
Void main()
{
int i;
for(i=1;i<=50;i++)
{
if(i%3==0)
{
printf("%d",i);
}
}
grtch();
}
| Is This Answer Correct ? | 24 Yes | 13 No |
Answer / narsi
#include<stdio.h>
#include<conio.h>
void main()
{
int n1,n2;
n1=1;
n2=50;
while(n1<=n2)
{
if(n1%3==0)
printf("%d ",n1);
n1=n1+1;
}
}
| Is This Answer Correct ? | 12 Yes | 4 No |
Answer / pruthiewraj swain
#include<stdio.h>
#include <conio.h>
voidmain()
{
int a ;
printf("enter the multiples of 3");
while (a=100)
{
if (a%3==0|| a%4==0)
}
printf("
%d",a);
}}
getch();
}
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / hemanth
#include<stdio.h>
#include<conio.h>
void main()
{
int n1,n2;
n1=1;
n2=50;
while(n1<=n2)
{
if(n1%3==0)
printf("%d ",n1);
n1=n1+1;
}
}
| Is This Answer Correct ? | 5 Yes | 6 No |
What is the difference between CV and Resume ?
char S; char S[6]= " HELLO"; printf("%s ",S[6]); output of the above program ? (0, ASCII 0, I,unpredictable)
Explain how do you use a pointer to a function?
write a sorting prgm to sort 50 nos and sum them and also remove all the occurrences of 15 and print it?
write a program for fibonaci series by using while loop in c?
Determine if a number is a power of 2 at O(1).
What is a nested formula?
What is structure and union in c?
Device an algorithm for weiler-atherton polygon clipping, where the clipping window can be any specified polygon
send me the code of flow chart generator using C-programming language amd this code should calculate the time and space complexity of the given progran and able to generate flowchart according to the given program?
how can i get the string which is having two spaces at the end.suppose the string is "Hello World ".Now at the end i have two spaces.i need to print with that spaces .
How can you restore a redirected standard stream?