aboutsummaryrefslogtreecommitdiff
path: root/examples/fib.sil
blob: b97472287702f04c70ca0a6131205c218ee7da05 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
Int fib(Int n) {
	if (n == 100) {
		return 100;
	} else {
		if (n == 200) {
			return 100;
		} else {
			return fib(n - 100) + fib(n - 200);
		};
	};
}

Int main() {
	return fib(1000);
}