My Little Game Jam
Competition Forum => Competition Freetalk => Topic started by: Rylius on 2012-October 05, 08:29:39
-
http://www.equestriadaily.com/2012/10/editorial-fim-pony-programming-language.html
Somepony implement this for the next MLGJ. :D
-
FiM++ Jam - Create an actually usable program in FiM++
-
Ponify ALL the things!
-
FiM++ Jam - Create an actually usable program in FiM++
Does making a program to list all the primes (sans 2) count? :D
JigPu
-
It's happening!
http://www.equestriadaily.com/2012/10/fim-update.html#more
-
Well, this was fun. I made a function that calculates the x-th fibonacci number in FiM++.
( public class "A letter about fibonacci numbers" { )
Dear Princess Celestia : A letter about fibonacci numbers
( double fibonacci(double position) { )
I learned the fibonacci number with a number using a number position:
( if (position == 0) { return 1; } )
If position was 0 then:
Then you get 1!
That's what I would do.
( if (position == 1) { return 1; } )
If position was 1 then:
Then you get 1!
That's what I would do.
( double "the previous one" = fibonacci(position - 1); )
Did you know that the previous one is a number?
The previous one is the fibonacci number using position minus 1!
( double "the one before the previous one" = fibonacci(position - 2); )
Did you know that the one before the previous one is a number?
The one before the previous one is the fibonacci number using position minus 2!
( double "the resulting number" = "the previous one" + "the one before the previous one"; )
Did you know that the resulting number is a number?
The resulting number is the previous one added to the one before the previous one!
( return "the resulting number"; )
Then you get the resulting number!
( } )
That's all about the fibonacci number.
( main() { )
Today I learned how to calculate fibonacci numbers recursively:
( double "the position of the desired number"; )
Did you know that the position of the desired number is a number?
( "the position of the desired number" = read(); )
I heard the position of the desired number.
( write(fibonacci("the position of the desired number")); )
I sang the fibonacci number using the position of the desired number.
( } )
That's all about how to calculate fibonacci numbers recursively.
( } )
Your faithful student, Twilight Sparkle
-
Wow... that's a lot to type.
-
Wow... that's a lot to type.
That's the fun part! :P
More seriously, using FiM++ improve your English in a way, so it's not that bad.
-
Here's the most advanced interpreter (apparently): https://github.com/KarolS/fimpp
Just wrote a small Hello Equestria script. Took me waaaay too long to figure out though!