I wasn't sure about putting this on the projects forum, since it's really only tangentially related with LÖVE, so I'm putting it here.
I've created a Lua Koans project. It's called Lua missions. It's here:
https://github.com/kikito/lua_missions
What are Koans?
Basically, they are tests (functions) that fail - at least initially. You have to fix them. In the process of fixing them, you learn a tiny bit of a language. It starts with the very basic and gradually moves up.
Yesterday I presented these to some people and they were quickly hooked up - they didn't want to leave the keyboard when time run out!
Disclaimer: This is not a finished thing, I'm aware that not the whole PiL is covered. (But a significant chunk already is). Feedback of any kind is encouraged and appreciated (as well as pull requests and forks).
Regards!
Lua missions (AKA Lua Koans) - Learn Lua while programming
- kikito
- Inner party member
- Posts: 3153
- Joined: Sat Oct 03, 2009 5:22 pm
- Location: Madrid, Spain
- Contact:
Lua missions (AKA Lua Koans) - Learn Lua while programming
When I write def I mean function.
Re: Lua missions (AKA Lua Koans) - Learn Lua while programmi
Looks neat! Though I think you missed swapping a few instances of Ruby to Lua in the readme:
README.rdoc wrote:nil is covered in nil.rb
README.rdoc wrote:Each mission builds up your knowledge of Ruby and builds upon itself.
README.rdoc wrote:If you do not have Ruby setup, please visit www.lua.org/download.html for operating specific instructions.
- bartbes
- Sex machine
- Posts: 4946
- Joined: Fri Aug 29, 2008 10:35 am
- Location: The Netherlands
- Contact:
Re: Lua missions (AKA Lua Koans) - Learn Lua while programmi
Awesome. But yeah, I don't install ruby from lua.org.
- kikito
- Inner party member
- Posts: 3153
- Joined: Sat Oct 03, 2009 5:22 pm
- Location: Madrid, Spain
- Contact:
Re: Lua missions (AKA Lua Koans) - Learn Lua while programmi
Thanks for the feedback!
I've just fixed this.
READMEs are my weak point.
I've just fixed this.
READMEs are my weak point.
When I write def I mean function.
Re: Lua missions (AKA Lua Koans) - Learn Lua while programmi
You should really post this to the Lua mailing list.
- kikito
- Inner party member
- Posts: 3153
- Joined: Sat Oct 03, 2009 5:22 pm
- Location: Madrid, Spain
- Contact:
Re: Lua missions (AKA Lua Koans) - Learn Lua while programmi
Yeah, the thought has crossed my mind. Maybe tonight. I spent the last week preparing it and a small activity for a group I'm in, and now I've got a considerable backlog. But yeah. I have to get in touch with those people at some point.
EDIT - Sent.
EDIT - Sent.
When I write def I mean function.
Re: Lua missions (AKA Lua Koans) - Learn Lua while programmi
Awesome. I'll be using those.
Mumon Ekai would disagree. But then, he probably won't. Zen is confusing. (But then it isn't)kikito wrote:What are Koans?
Basically, they are tests (functions) that fail - at least initially.
- TechnoCat
- Inner party member
- Posts: 1611
- Joined: Thu Jul 30, 2009 12:31 am
- Location: Milwaukee, WI
- Contact:
Re: Lua missions (AKA Lua Koans) - Learn Lua while programmi
string is using the # table operator before it is taught. strings.lua:54,59
also, test_numbers_must_be_converted_to_strings_before_concatenation at strings.lua:76. I don't know this to be true. Seems you can just concat numbers in Lua.
strings.lua:105 should be string.upper(str)
also, test_numbers_must_be_converted_to_strings_before_concatenation at strings.lua:76. I don't know this to be true. Seems you can just concat numbers in Lua.
strings.lua:105 should be string.upper(str)
- kikito
- Inner party member
- Posts: 3153
- Joined: Sat Oct 03, 2009 5:22 pm
- Location: Madrid, Spain
- Contact:
Re: Lua missions (AKA Lua Koans) - Learn Lua while programmi
I've fixed those issues in string.lua
Thanks!
Thanks!
When I write def I mean function.
- TechnoCat
- Inner party member
- Posts: 1611
- Joined: Thu Jul 30, 2009 12:31 am
- Location: Milwaukee, WI
- Contact:
Re: Lua missions (AKA Lua Koans) - Learn Lua while programmi
I think exercises.lua needs a fizzbuzz http://imranontech.com/2007/01/24/using ... ok-coding/
Who is online
Users browsing this forum: Google [Bot] and 4 guests