Browse Source

Add fib example

github-actions
Garrit Franke 2 years ago
parent
commit
0113546cc8
  1. 4
      examples/fib.sb
  2. 3
      examples/playground.sb

4
examples/math.sb → examples/fib.sb

@ -1,9 +1,9 @@
fn main() {
main :: () {
let num = 10;
print(fib(num));
}
fn fib(n int) int {
fib :: (n) {
if (n <= 1) {
return n;
}

3
examples/playground.sb

@ -0,0 +1,3 @@
main :: () {
}
Loading…
Cancel
Save