FOSCON: Some people have all the fun
From comp.lang.ruby on why the lucky stiff's presentation:
"He had people fire up irb and then displayed some code they would need to log into his drb server running on his laptop. As each person logged in the colors on the projected screen changed and it would divide into different regions so you could tell how many people were logged in. Audience members could change colors on Why's display by changine their code in irb. It was very cool... though some wise guy changed part of the screen to white-on-white which made it impossible to read the code on that section (but Why got some jokes out of this too).
Why's talk was extremely funny so it can be easy to overlook the fact that this was a very innovative idea for creating an interactive presentation. Most presentations are all one-sided: A speaker delivers some information to an audience - there may be a Q&A session afterwards, but other than that it's not interactive at all. What Why did last night, I've not seen before: He invited the audience to directly participate and even effect his presentation. This aspect deserves a lot more examination.
One can imagine variations on this theme: For example you could run a webrick server on your laptop and allow audience members to interact with (and potentially effect) your presentation through their browsers. Lots of potential uses: audience voting in real time, for example. Code contests with the audience. It's great for tutorials (This is how Why used it): you get people to actually try out the code you're talking about with some kind of feedback to the speaker. Nobody gets bored.
I think that Ruby historians and sociologists will look at this event as a seminal development in the direction of interactive teaching.
Oh, and two shadow puppet birds debated teaching methodologies just prior to this part of the show - that was no accident."
More photos are available on flickr. I really wish that I was there. It would be interesting to see how to teach ruby with puppets and such. Right now I hope that why releases his irb thingy for public perusal. Why is definitely one creative fellow. He is right up there on the list of people I look up to; right along with David Heinemeier Hansson.
Posted in web pages, ruby | no comments |
O'Reilly CodeZoo
O'Reilly CodeZoo: "After our launch in April, we received requests for many languages, but no language got more requests than Python. We're happy to have Python represented on CodeZoo, and will be adding still more components to the Python tab over the next few weeks. Visit python.codezoo.com to get right to CodeZoo's 'Reptile House.'
Seeing all the excitement around Ruby, particularly Ruby on Rails, we felt it would make an excellent addition to CodeZoo. Whenever possible, we're providing a RubyGems-format download as the default (and we'll start up a Gems server shortly). Check out ruby.codezoo.com and see what all the fuss is about."
(Via @lesscode.)
Though I am neutral for the inclusion of Python as part of codezoo, I am really excited about Ruby's inclusion. Maybe people have really seen what a great language it can be.
Posted in web pages, ruby | no comments |
Ruby on Rails framework creator awarded Best Hacker!
Winning Google/O'Reilly's Best Hacker of '05 (Loud Thinking): "The ego inflation just culminated in a near pop. The Google-O'Reilly Open Source Awards granted me the great honor of being named "Best Hacker" of the year for the work with Ruby on Rails"
Well deserved award! When you see companies such as Google and O'Reilly giving out awards, you know that those awards are not some stupid corporate pieces of bullcrap. This is one real achievement, both for David and also the Ruby on Rails community. There is definitely some essence to all the hype about Ruby and Rails.
Hopefully the next time around, Lips on Lines wins the award. One can dream cant't he?
Posted in paradigm, readings, ruby | no comments |
Learning LISP
After reading Paul Graham's essays and his bias in favor of Lisp, I finally joined in the bandwagon. Surprisingly, WikiPedia has this to say about Lisp:
Having declined somewhat in the 1990s, Lisp has experienced a regrowth of interest since 2000, partly due to the writings of Paul Graham.I never knew that he had that much influence. Well, anyway, I picked up a copy of the Little LISPer from the library. Unfortunately, this book is no longer available for sale (it has been replaced by the Little Schemer, which I hear has about the same contents). Now, the Little LISPer is an interesting book. Instead of having page after page of words, it has page after page of conversations! Each page is formatted into two columns, one for the dialogue of the teacher and the other for the student. And their conversation revolves around LISP, recursion (lots of it) and food! For a sample of what these conversations sound like, I direct you to Brian Marick's implementation of this style of writing for Ruby.
LISP seems to be an interesting language. So far the Little LISPer has focused more on recursion than features of the language, so I am not able to see how to use LISP to do more complex stuff. There are libraries written for it that can do GUI because it was in the tutorial for my IDE. I have also ordered a copy of ANSI Common LISP from the library. Paul Graham promises that it has the best explanation for macros. And it even has 20 substantial examples for showcasing the power of LISP.
Anyway, my motivation for learning LISP is to verify how much of what Paul Graham says is true. He believes that languages are evolving more toward what LISP is. Here is a diagram that shows how Ruby came about. I pilfered it from the book
Game Programming with Lua, Python and Ruby. I sincerely hope that you do not buy this book. I have browsed through it and am really disappointed with its contents. Then again, I have never been pleased with the Game Developer series; the book lacks depth and tries to make up for it by having a CD that is loaded with all kinds of crap. The reviews for it on Amazon agrees with me. But, anyway, here is the diagram:

No doubt, lambda (or Proc, as they are called in Ruby) seems to the common ground for this languages. Not to mention the fact that metaprogramming is an important feature for LISP. One, that paved the way for its popularity in Artificial Intelligence. Why (yes he is called Why or rather Why, the lucky stiff) has written two nice articles on metaprogramming on Ruby: Seeing Metaclass Clearly and A Sponsored Dragon-Slaying.
So, right now, the method that I am deploying for learning LISP falls along the lines of writing little programs and some test cases for them. This methodology is similar to the one suggested by Mike Clark. And for my IDE, I chose LISPWorks Personal Edition as it was recommended on the LISP newsgroup.
Posted in development, readings, software, ruby, lisp | no comments |
Show your passion: get a t-shirt!
I was planning to get a Ruby t-shirt. So I made the purchase today and bought two:
Ironically, what motivated me was this post about Java and people wearing Java t-shirts! No! The Rubyist in me cannot bear to see those guys around totting their Java stuff.
Posted in college stuff, ruby | no comments |
Design Patterns and Languages
The original authority on Design Patterns is the Gang of Four book. The Gang of Four includes my Software Engineering professor, Dr. Ralph Johnson. Design Patterns is still a good book and all; however, it focuses a lot more of implementing it using C++. Thus, I bought the Head First Design Patterns book. Except for its startling front cover, Head First Design Patterns is an excellent book. I read through 5 chapters of it last night after the book arrived. The exercises in there are fun, with the exception of the crossword puzzles. Why are there crossword puzzles?
Anyway, from what I have read -- and this is still very preliminary -- most of the design patterns seem to be used for delaying initialization to runtime. That is, all functionality should be freely dynamic and can be added and changed at runtime. Thus, design patterns seem more like little hacks (pardon me for a lack of a better word) to get the static type-based languages to be more dynamic.
I do not think that I am the only one to think this. Peter Norvig has some slides that show how to use design patterns in dynamic languages. In fact, he says that 16 of the 23 patterns discussed in Design Patterns are more easily implemented using Lisp than C++. Needless to say, this is something that I am really interested in finding out more on. And as a side note, this brings me back to what Paul Graham thinks: there is indeed the dream language. It would not do justice to his excellent essay on how he goes on to describe why some languages are indeed better. If you excuse him for his bigotry toward other languages beside Lisp, you might come to agree with him that there is indeed an evolution of languages. New languages tend to be more dynamic and not as type-based. Also, new languages tend to be flexible enough that you are able to define new constructs for the languages so that it models your software better.
Maybe, I am just language-addicted. Dave Thomas, one of the Pragmatic Programmers, mentions in a recent Ruby on Rails podcast that he is interested in languages too. And that he always strives to spend 3 minutes on each new language that he encounters, devoting more time to it if he finds it interesting.
In short, what I would really want to find out: Are Design Patterns modeled after the limitations of the language? Or do their usefulness transcend between languages?
Posted in readings, software, ruby, lisp | no comments |
42things
By the way, the picture above shows my latest project. 42things.com an emulation of 43things.com. All done in Ruby on Rails goodness. Ruby is becoming my favorite language.
The actual coding took less than a week. But if you count in total numbers of hours actually spent coding, it is about 24 hours. Most of the time, we were tweaking the database schema so that it is more normalized.
Some features supported:
- Searching
- User accounts
- Comments
- Entries for items the user is doing
- Related tags
- Related items
Posted in development, software, ruby | no comments |
Spring Break entries
Spend time all alone for Spring Break. EOF
Though here are some interesting things that happened:
- Had to pay $600 for a new pair of glasses
Unfortunately the pair that I own was broken by a toilet roll. I dropped the toilet roll while trying to put in on the top of the cabinet. Though the toilet roll weights only very little, the impact must have loosened the screw. I did try fixing it but I lost the screw in the process.
Because of the way the system works here for making new glasses, I had to go for an eye examination first. It was basically the same routine testing like the ones they did back in Malaysia. However because it was done by a certified optometrist, he could charge me $50 for it.
The lenses themselves cost $265 + $70. $265 was for the normal lenses. There is no way I was going to get cheap lenses. I had to have multi-coated anti-reflection as well as medium-index lenses. The $70 was for transition lenses.
The rimless frame itself was about $200.
And that is it. So even if I wanted to save money by not going anywhere, I ended up spending more money that I would have had I gone to Vegas instead. But I can also look at it this way, had I gone to Vegas and broken my glasses too, then I would have ended up spending much more.
The new pair of spectacles will only arrive in two weeks so until then I have to make do with my repair and some super-handy super glue. - Manga Marathon
Decided to read some manga that I would not have read if I did not have the time. I had always wanted to read Inuyasha because it was a very well-developed manga. And it was really long too. In fact it is one of the longer running mangas that I know. It is currently at its 400th chapter. In fact, Inuyasha is not like most of the manga I am used to. It does not involve fighting tournaments and all the usual stuff. I was really impressed by how the illustrator weave the different characters together. And she has successfully made the story that much more interesting. The number of main characters that she choose was just right too. It was neither too many nor too little and each had the chance to show their character fully. The anime is rather good too. Also she keeps you in suspense and does not reveal too much of what will happen next.
But I also decided to read some romance/ comedy manga. And those prove to be very enjoyable too. It was a nice experience compared to the other types of manga. Besides, the fact that these novels are usually short make them fun to read too. I just spend around 6 hours to finish the whole series.
There are of course those that are really long. But they are mostly just to satisfy their loyal fans. I do not really enjoy those since it seems that the story has been protracted just to make the fans happy. Thus the story feels boring because they have to keep introducing new characters. And they are stalling the (inevitable) ending.
Also, despite some negative reviews for this manga, Love Hina was a really nice read. I just finished it an hour ago and it was rather satisfying. I mean there were ridiculous moments but its length was just right. There were no unnecessarily drawings just to make the manga longer. And there weren't too many characters as well. Also the fact that it revolves around the live of students trying to get into a top university makes it slightly pertinent to my current life. The author was also kind enough to write that this is a story and it is not so simple to actually get into a top university.
I learned a bit more about how the exam system in Japan works too and it was rather interesting. Having to take public exams and the the university's own entrance exam to get in. I was also to learn about some of the festivals that they celebrate. And the fact that some students actually go to dormitories to study even though their house might be near the place so that they can concentrate.
I *would* probably recommend Love Hina to most people. It is really funny. And it has a nice ending. The fact that the characters were not ridiculous looking was also a nice point for it. I really hate manga where the characters are a bit too disproportionate. - Ruby Rocks
It is set to become one of my favorite languages. It seems so lightweight. And the fact that is allows these little notations such asdef myName=(_name)
makes the language so much more interesting. For those not familiar with Ruby, the above create a setter for the class variable @name. The use of the = sign is just plain genius. In C or Java you would probably call the method setMyName. These simple things do not exist in other languages. It would seem that the Japanese creator actually took some time to think of subtle issues like this. The use of ! as in !gsub for string substitution that replaces the original string and also the use of ? for boolean is a nice change from having to say isValid.
@name = _name
end
Because Ruby's creator is a Japanese, I believe he takes the time to focus on the subtle points. As native English speakers, we might take certain things for granted and do it just as how the other languages have done it but Ruby is really different because of its notations.
Posted in paradigm, readings, ruby | no comments |
Ruby & Rails: Resources
I should really spend more time learning Ruby and Rails. I am really hooked by the claims that people are making. Here are two newly discovered resources:
It does seem that I am easily swayed toward some new technology depending on how passionate its users are talking/ blogging about it.
Posted in development, ruby | no comments |
Of Ruby and its "poignance". And a bit of Rails thrown in for good measure.
Ruby seems to be a nice language to learn. Though I was planning to learn Python at first because it seems to have a much stronger user group, the past few weeks brought about many different encounters with Ruby. The first time I saw it after a long time of not paying attention to it was on 43things.com. Learn Ruby was one of the most highly rated items to do. Then it was when someone in my CS498 class did his presentation on it. Then it was when I saw it on www.rubyonrails.com. Finally I had no choice but to give myself a reason for learning it.
And then comes the reason, we will be using RubyonRails for our CS411 database class project. It was my suggestion. For short of any better ideas, we are going to emulate the site 43things.com and without much creativity, call ours 42things.com. And in case you are wondering, our group is called MySQuirreL for a lack of a better name (actually the name was thought up by Mark and it was actually quite creative). Since we are doing this for academic purposes, we hope that we will not be sued. So, with the perfect and unavoidable reason of learning Ruby, I decided to buy the book: "The Pragmatic Programmer's Guide to Ruby". The first edition of this book is available online but it only talks about Ruby 1.6. The current version of Ruby is 1.8.2 and it has undergone substantial changes.
While waiting for my book to arrive, I have also been perusing an online guide written by someone by the name of why. I have not found out anything else about his identity and neither would I bother to. Anyway, his poignant guide to ruby can be found at why's poignant guide to Ruby. This book is written in a very unconventional way that might piss people off. I had a hard time reading this book the first time I saw it. However I decided to give it a second chance. The comic strips in there might throw some readers off. Personally I did not get all why's jokes.
The fact that why actually tries to explain object-oriented programming in that manner is quite laudable. While it might annoy some of the purists, it might be easier for the beginner. There is this mistake in chapter 4 though:
I don’t think reverse is going to cut it. The authorities only need to put a mirror to “airegiN fo noissessop ekaT.” Bust us when starmonkeys start to touch down in Lagos.I will probably e-mail him (or her) on that. You do not use a mirror to read something that has just been spelled backwards. Again, his work is praiseworthy.
I have also been following the resources at article on the O'Reilly website is helpful on how to get multiple tables set up.
Well that seems to be a decent introduction into my foray with Ruby and RubyonRails. I would encourage anyone reading this to actually go and tinkle with it. For a web application framework setting it up is pretty easy. And its simplicity might well be what it needs to penetrate something dominated by .asp and .jsp pages.
Posted in college stuff, development, ruby |
