program for following output using for loop?
1 2 3 4 5
2 3 4 5
3 4 5
4 5
5
Answer Posted / rajarshi bhadra
#include<stdio.h>
#include<conio.h>
void main()
{
int i,j;
clrscr();
for(i=5;i>=0;i--)
{
for(j=1;j<=i;j++)
{
printf("%d",j);
}
printf("\n");
}
getch();
}
| Is This Answer Correct ? | 4 Yes | 7 No |
Post New Answer View All Answers
What is the difference between printf and scanf in c?
What is c token?
Explain the use of fflush() function?
how to find binary of number?
Explain the difference between getch() and getche() in c?
Sir i need notes for structure,functions,pointers in c language can you help me please
How many main () function we can have in a project?
What is abstract data structure in c?
Study the following C program :call_me (myvar)int myvar;{ myvar +- 5; }main(){int myvar;myvar = 3;call_me(myvar);printf("%d ",myvar);What will be printed a) 3 b) 5 c) 8 d) symbol
The number of bytes of storage occupied by short, int and long are a) 2, 2 and 4 b) 2, 4 and 4 c) 4, 4 and 4 d) none
Is fortran faster than c?
The number of measuring units from an arbitarary starting point in a record,area,or control block to some other point a) recording pointer b) offset c) branching d) none
How to declare a variable?
what type of questions arrive in interview over c programming?
What are the types of data types and explain?