gitweb on Svarog
projekti pod git sistemom za održavanje verzija -- projects under the git version control system
summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 8f8cbd8)
raw | patch | inline | side by side (parent: 8f8cbd8)
author | Doni Pracner <quinnuendo@gmail.com> | |
Sat, 4 Jan 2014 22:39:29 +0000 (23:39 +0100) | ||
committer | Doni Pracner <quinnuendo@gmail.com> | |
Sat, 4 Jan 2014 22:39:29 +0000 (23:39 +0100) |
samples/RekFib.mj | [new file with mode: 0644] | patch | blob |
diff --git a/samples/RekFib.mj b/samples/RekFib.mj
--- /dev/null
+++ b/samples/RekFib.mj
@@ -0,0 +1,16 @@
+program RekFib{
+
+ int fib(int f)
+ {
+ if (f==0) return 0;
+ if (f==1) return 1;
+ return fib(f-1)+fib(f-2) ;
+ }
+
+ void main()
+ int i;
+ {
+ print(fib(0));
+ print(fib(7));
+ }
+}
\ No newline at end of file