diff options
author | Piotr Dziwinski <piotrdz@gmail.com> | 2013-03-30 15:01:00 +0100 |
---|---|---|
committer | Piotr Dziwinski <piotrdz@gmail.com> | 2013-03-30 15:23:05 +0100 |
commit | e218dcfdf2c58f8841e7ebd220527d08e870a6d5 (patch) | |
tree | a567db04a8a51e2db87f80e259faf222a7d4becd /src/CBot/tests/scenarios/fibo.txt | |
parent | bfc701e286259d9a7aa2ff8240704eab2ba3a237 (diff) | |
parent | e607fed265070be8c518d4302d8b76f738421fb3 (diff) | |
download | colobot-e218dcfdf2c58f8841e7ebd220527d08e870a6d5.tar.gz colobot-e218dcfdf2c58f8841e7ebd220527d08e870a6d5.tar.bz2 colobot-e218dcfdf2c58f8841e7ebd220527d08e870a6d5.zip |
Merge branch 'dev'
Merging content from dev
Diffstat (limited to 'src/CBot/tests/scenarios/fibo.txt')
-rw-r--r-- | src/CBot/tests/scenarios/fibo.txt | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/src/CBot/tests/scenarios/fibo.txt b/src/CBot/tests/scenarios/fibo.txt deleted file mode 100644 index 88f5357..0000000 --- a/src/CBot/tests/scenarios/fibo.txt +++ /dev/null @@ -1,25 +0,0 @@ -
-extern public int Fibo( int n, boolean b )
-{
- if ( n < 2 ) return n;
- int a = Fibo(n-1, b) + Fibo(n-2, false);
- if ( b ) print (n + "=" + a);
- return a;
-}
-
-extern public void t()
-{
- Fibo( 23, true);
-}
-
-extern public void tt()
-{
- t();
-}
-
-// cette routine n'est évidemment pas du tout obtimisée
-// c'est même un très mauvais exemple de programmation récursive
-
-// pour un test de durée, Fibo(23, true) prend
-// en mode Debug 67 secondes
-// en mode Release 8 secondes
|