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 / vignesh1988i
super problem this is......
#include<stdio.h>
#include<conio.h>
void main()
{
int count ,m,n;
printf("enter the size :");
scanf("%d",&m);
printf("enter the seed :");
scanf("%d",&n);
count =n;
for(int i=1;i<=m;i++)
{
printf("\n");
for(j=1;j<=i;j++)
{
printf("%d",count);
count++;
if(count>=10)
count=1;
}
}
getch();
}
thank you
| Is This Answer Correct ? | 10 Yes | 3 No |
Post New Answer View All Answers
Write a c program to demonstrate character and string constants?
What is a null pointer in c?
Disadvantages of C language.
How would you rename a function in C?
Explain the difference between malloc() and calloc() function?
What is const keyword in c?
about c language
What is a macro in c preprocessor?
Write a code to generate divisors of an integer?
Which is better malloc or calloc?
Find MAXIMUM of three distinct integers using a single C statement
largest Of three Number using without if condition?
Write the test cases for checking a variable having value in range -10.0 to +10.0?
int far *near * p; means
what is the basis for selection of arrays or pointers as data structure in a program