codegen: handle exceptions of a method
[mate.git] / tests / Fib.java
1 package tests;
2
3 public class Fib {
4         public static int fib(int n) {
5                 if (n <= 1)
6                         return 1;
7                 else
8                         return fib(n - 1) + fib(n - 2);
9         }
10
11         public static void main(String[] args) {
12                 System.out.printf("result: 0x%08x\n", fib(20));
13         }
14 }