parkside's triangle..

create a program like this..

enter the size: 6
enter the seed: 1

output:

1
23
456
7891
23456
789123

sample2:

enter the size: 5
enter the seed: 3

output:

3
45
678
9123
45678

parkside should not exceed 10 while its seed should only be
not more than 9..

Answer Posted / prashant

#include<stdio.h>
#include<conio.h>
void main()
{
int i;
printf("enter the size");
scanf("%d",&n1);
printf("enter the seed");
scanf("%d",&n2);
for(i=1;i<n1;i++)
{
for(j=1;j<=i;j++)
{
printf("%d",j);
}
printf("\n");
}
getch();
}

Is This Answer Correct ?    2 Yes 9 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

write a program to print the consecutive repeated character from the given string... input string is : hhhhjkutskkkkkggggj output should be like this: hhhhkkkkkgggg anyone help me...

1581


how we can make 3d venturing graphics on outer interface

4169


What is a double c?

678


main use of recursive function a) processing speed high b) reduce program length/reduce repeated statements c) if you do not, use iterative methods like, for, while or do-while d) all the above

708


What are enums in c?

751






What are the types of pointers in c?

634


What is a node in c?

650


Can you assign a different address to an array tag?

800


What is the difference between variable declaration and variable definition in c?

654


Explain how do you list files in a directory?

719


swap 2 numbers without using third variable?

751


Give basis knowledge of web designing ...

1671


Write a Program to accept different goods with the number, price and date of purchase and display them

5689


When is a null pointer used?

730


Why c is called free form language?

660