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...

write a program whose output will be-
1
12
123
1234

Answer Posted / tanish kumar

#include <iostream.h>
#include <conio.h>
void main()
{
clrscr ();
int i, j, n;
cout <<"Enter the value of n=";
cin>>n;
for (i=1;i <=n;i++)
{
for (j=1;j <=i;j++)
{
cout <<j <<" ";
}
cout <<endl;
}
getch ();
}

Is This Answer Correct ?    2 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is #define in c?

1048


What are near, far and huge pointers?

1059


What are qualifiers?

1051


What is f'n in math?

1071


Write a program that accept anumber in words

1761


What does d mean?

1094


Explain what are multidimensional arrays?

1072


writ a program to compare using strcmp VIVA and viva with its output.

2024


List some basic data types in c?

1029


What is the difference between struct and union in C?

1316


What is the difference between int main and void main in c?

1182


What is the difference between a function and a method in c?

1085


what do the 'c' and 'v' in argc and argv stand for?

1176


Explain how do you use a pointer to a function?

1111


What is the meaning of c in c language?

1172