Computer Science, asked by tiariti, 4 months ago


write a program in java to display the first 10
numbers of the fibonacci series 0, 1, 2, 3,
A program to display the first ten numbers of
the Fibonacci series
public class Fibonacci
public static void main(String args[])
inta, b, c, n; a=0; b=1; c=0; n = 3;
System.out.println ("The Fibonacci series is");
System.out.println (a);
System.out.println (b);
for (i=0; i <= 7; i++)
{
C = a+b;
System.out.println (c);
a = b
b=c
}
}
} predict the output
pls help smone gotta submit it tommorow​

Answers

Answered by amboy17
0

Answer:

I think i =0 should be i=1

Similar questions