...all your told it to do was print zeros...
Generally loops have 4 parts: Setup (initialization), looped code, the increment, exit condition. Now these are just names I am making up but here is the idea behind each part:
setup: do whatever you need to set up the conditions for the loop
loop: some code that you want to repeat.
increment: CHANGE SOMETHING, preferably so that at some point your exit condition will happen.
exit condition: how do we get OUT of the loop? Note this must be linked to the "increment" step.
lets take a look at one of your loops:
QUOTE
CODE
while (Fibonaccinumbers > 0)
{
cout << Fibonaccinumbers << endl;
count = count + 1;
} //end while
Now the problem here is that you have an increment but it is not linked to your condition... the only thing that changes is count. -- also note that you are trying to display Fibonacci numbers but the variable Fibonaccinumbers does not change at all... which is why you just point '0' over and over.
So... in order for your program to work you have to THINK about the logic of the loop in your head.
to calculate the Fibonacci numbers you are going to need SOMETHING that does the following 1 + 1 = 2, 1 + 2 = 3, 2 + 3 = 5.
So a basic pseudo-code for this might be:
CODE
//First we need to set things up...
old = 1
new = 1
while (new < 100) { //Our exit condition is when we get above 100
temp = new; //Save the current number
new += old; //calculate the next number (This is our increment step -- note that it changes the variable used in the condition).
old = temp; //ditch the old-old number and save the last number
output new; //current Fibonacci number
}
I warn you that that code will not work exactly as-is in C/C++ but it should give you an idea of how to change your program to work.