Write a program for the following series?

1
121
12321
1234321
123454321
12345654321
1234567654321
123456787654321
12345678987654321
1234567890987654321
123456789010987654321
12345678901210987654321
1234567890123210987654321
.........1234321............
..........123454321............
..........12345654321............
7
8
9
0
1
Pls............?

Answer Posted / kkx

hi this is no the pgrm
let u want to find nth number


value = "n";
while(n-1)
{
value = value+ "n-1";
value= "n-1" + value;
n= n-1;
}

Is This Answer Correct ?    7 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

program for reversing a selected line word by word when multiple lines are given without using strrev

1941


What are the 3 types of structures?

568


What do you mean by dynamic memory allocation in c? What functions are used?

650


How do I read the arrow keys? What about function keys?

610


What are structure members?

590






What is the difference between ++a and a++?

686


At a shop of marbles, packs of marbles are prepared. Packets are named A, B, C, D, E …….. All packets are kept in a VERTICAL SHELF in random order. Any numbers of packets with these names could be kept in that shelf as in this example: bottom of shelf ---> [AAAJKRDFDEWAAYFYYKK]-----Top of shelf. All these packets are to be loaded on cars. The cars are lined in order, so that the packet could be loaded on them. The cars are also named [A, B, C, D, E,………….]. Each Car will load the packet with the same alphabet. So, for example, car ‘A’ will load all the packets with name ‘A’. Each particular car will come at the loading point only once. The cars will come at the loading point in alphabetical order. So, car ‘B’ will come and take all the packets with name ‘B’ from the shelf, then car ‘C’ will come. No matter how deep in the shelf any packet ‘B’ is, all of the ‘B’ packets will be displaced before the ‘C’ car arrives. For that purpose, some additional shelves are provided. The packets which are after the packet B, are kept in those shelves. Any one of these shelves contains only packets, having the same name. For example, if any particular shelf is used and if a packet with name X is in it, then only the packets having names X will be kept in it. That shelf will look like [XXXXXXX]. If any shelf is used once, then it could be used again only if it is vacant. Packets from the initial shelf could be unloaded from top only. Write a program that finds the minimum total number of shelves, including the initial one required for this loading process.

1730


what is the height of tree if leaf node is at level 3. please explain

1595


How can I call a function with an argument list built up at run time?

631


What is wrong with this declaration?

608


How can I read in an object file and jump to locations in it?

573


What are preprocessor directives in c?

630


What is a stream?

642


Describe the order of precedence with regards to operators in C.

631


Can an array be an Ivalue?

657