diff --git a/notes/10.1 斐波那契数列.md b/notes/10.1 斐波那契数列.md index fd9e836b..a936422b 100644 --- a/notes/10.1 斐波那契数列.md +++ b/notes/10.1 斐波那契数列.md @@ -31,6 +31,22 @@ public int Fibonacci(int n) { return fib[n]; } ``` +OR Simplified code +class FibonacciExample1{ +public static void main(String args[]) +{ + int n1=0,n2=1,n3,i,count=10; + System.out.print(n1+" "+n2);//printing 0 and 1 + + for(i=2;i