Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

program for following output using for loop?
1 2 3 4 5
2 3 4 5
3 4 5
4 5
5

Answer Posted / jayaraj.s

#include <stdio.h>
main()
{
int a,b,i=1;
for(a=i;a<=5;a++)
{
for(b=a;b<=5;b++)
{
printf("%d",b);
}
printf("\n");
i++;
}
getch();
}

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which is the memory area not included in C program? give the reason

1934


Are the variables argc and argv are local to main?

1301


Explain can the sizeof operator be used to tell the size of an array passed to a function?

1058


What is a stream?

1122


What is the maximum no. of arguments that can be given in a command line in C.?

1128


How can I sort more data than will fit in memory?

1087


How can I call fortran?

1028


What is #include conio h?

991


Write a program to find factorial of a number using recursive function.

1109


Is there any possibility to create customized header file with c programming language?

1052


How to write a code for reverse of string without using string functions?

2126


What is dynamic dispatch in c++?

1041


Define Array of pointers.

1091


Write a program to replace n bits from the position p of the bit representation of an inputted character x with the one's complement. Method invertBit takes 3 parameters x as input character, p as position and n as the number of positions from p. Replace n bits from pth position in 8 bit character x. Then return the characters by inverting the bits.

4191


How do you determine a file’s attributes?

1070