how can i get the output
54321
4321
321
21
1

in c programming........???? pls help......

Answer Posted / rishabh upadhyay

#include<stdio.h>
void main(){
int i,j=5,temp=0;
for (i=1;i<=5;i++)
{
for (j=5-temp;j>=1;j--)
{
printf("%d",j);
}
printf("
");
temp=temp+1;
}
}

Is This Answer Correct ?    1 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is c is a low level language?

567


What are pointers?

635


Is flag a keyword in c?

682


What are the two types of structure?

579


Why main is used in c?

590






What is void main () in c?

735


How can I determine whether a machines byte order is big-endian or little-endian?

622


What is the difference between exit() and _exit() function?

607


What is output redirection?

695


Explain what is wrong with this program statement?

622


How does pointer work in c?

622


Iam a B.Tech graduate and completed my engineering in 2009, from 2005 to 2009 and after that i had done nothing.Now i want to do job and get into BPO field . Friends give me suggestions as what to say in interview... if they ask me that what would you had done ... these many years without doing job ??????? pls urgent

1432


What is difference between structure and union?

603


What is advantage of pointer in c?

696


Why header file is used in c?

578