How many numbers do you want to add: 2023581321345589144233377610987159725844181676510946

This is grate :mrgreen: but... i need something more! ;)

I need the programe outcome to be something like this:

How many numbers do you want to add: 20How many elements in a number you want to output: 3

144233377610987

The program sould output all numbers that have 3 elements.
Ofcors if I enter 4 in "How many elements in a number you want to output:" The program sould output numbers that have 4 elements (for example 10946 atc.)

I hope you will understand me :confused: .... I`m not realy good in spelling... :sad:
Help me please ;) :o

strange, i can imput "How many numbers do you want to add: " and "How many number of digits you want to output: "; but, somehow the risult doesnt apear... whats wrong?...

In the sequence, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144 a three digit number, if that's the number of digits you want, doesn't appear until the tenth iteration, so are you going round the loop enough times? A four digit number doesn't appear until the fifteenth iteration.

eh.. still doesnt work... i dont get it... it must work... i dont see any mistakes...
may be there sould be a "hold screen" function? or something?...

I can see the mistake:

if( ( a[fN] > pow( 10, n - 1 ) - 1 ) && ( a[fN] < pow( 10, N ) ) )

Note the upper case N in the second call to pow. In C N and n are two different variable names. You have declared N as an int, but, so far as I can see, having declared it you don't use it again. Most likely it is initialsied to zero, and pow( 10, N ) then always returns the value 1.

Or maybe because system ("pause") is guaranteed to stop the console window no matter how much junk is left off in the input stream.When getchar ( ) is used, one must be pretty sure that the input stream does not have a pending '\n'.
But then again, sytem ( "pause" ) is bad... ;)