Archive for August, 2008

Living in a modern pyramid

Wednesday, August 27th, 2008

Heard about this in the news a couple of days ago. A Dubai-based environmental design firm, TimeLinks, is planning to unveil it’s newest “structure”, which is really a city-within-a-pyramid, called the Ziggurat:

Behold, the Ziggurat

Behold, the Ziggurat

This thing will supposedly be able to house up to 1 million people and have no cars. You may ask, how will they live without cars?

Fear not! They’ll have  modern transportation system within the structure that runs both vertically and horizontally. I’m envisioning the Futurama tube system…

This city is supposed to be carbon neutral, using only natural energy from the wind, water, sun and so on.

I think I’m going to start saving today for a chance of saving my soul in the city of the future!

Utah is the new Nigeria

Tuesday, August 26th, 2008
Spamming (CC image)

I was selling some stuff on craigslist when and got a very generic email response from a potential buyer that said something along the lines of “I’d like to buy your item. Is the item available? Please respond urgently!!” That sounded a bit strange and spammy, so I responded from a special “Just for spam” email address saying it was available. Here’s what I got back in response:

Thanks for your prompt response,My name is Mike larry  located in Utah, i am currently out of the state on a pastoral mission.

I am buying the item for our pastor who is recently getting married to a California woman that is working in West Africa Embassy as a wedding present.

So you will be sending it to them once you receive the confirmation of my payment. I would have love to pick it up by my self, but i am out of the state now on a pastoral mission And i don’t want to disappointed them.

Please send me a paypal request to enable me to make the payment right away. through paypal,or the information that i will use to send you a u.s postal money order,I will like this item to get to them before the wedding. i will add additional extra $180 USD during payment for the shipment cost, Because you will be required to ship it express through u.p.s to them.thanks

Mr Mike larry

Now I’m just eagerly waiting for that wonderful extra $180!!1!1!!

Learning to read

Monday, August 18th, 2008
Image licensed under Creative Commons

Image licensed under Creative Commons

No, this is not a post about illiteracy.

OK, now that I got that off my shoulders…

I’ve been learning Ruby on Rails for the past few weeks, and I’ve encountered an interesting question that I’ve faced a few times before and never really found a good answer to.

How do you read code?

And I don’t mean that in a metaphysical sense. I mean when you’re learning a new framework, language or technology you usually look at some code written in it to try and see how real world applications use it. These days you can pretty easily find Open Source code written in almost anything. What I find difficult is figuring how to read the code of these applications.

I’ve read a book about Ruby on Rails, so I understand the basics decently well. I’ve created a toy application just to see how to do it. But the jump from that to digging through source code for a full fledged real application is pretty huge. Where do you start? Initally I started looking at the models to try and understand the objects that the application dealt with. But I found that to be a bit confusing. Then I looked at some of the key controllers (like user authentication and those that handle the main pages) and also found that a bit confusing.

Finally I sort of settled on looking at a specific page in the app, looking through the view that generated it, then going to the controller that was invoked, and maybe looking at some helper methods and model code that I found there. I found that to be a reasonably understandable strategy. But I’m not really sure if it would have worked as well if I didn’t already have looked at some model/controller code before hand.

This is not specific to RoR. If you learn a new development environment, how do you figure out where to learn the code?

Googled

Friday, August 8th, 2008


View Larger Map

Click View Larger Map to see more…

Recent Readings

Tuesday, August 5th, 2008

I’ve been asked a few times in the past few weeks about books that I’m reading, mostly because I tend to carry them around with me a lot. So I decided to write a bit about them. Maybe I’ll inspire a new generation of wonderful, socially-outcast bookworms. Or maybe I’m just bored. Here goes.

The Jungle
This is a story describing the horrors of the Chicago meat packing industry at the turn of the 20th century. The story follows a large fictional family of immigrants from Lithuania coming to the land of opportunities, and hoping for a better life. Instead they end up being enslaved by the Chicago meat packers, and starved to death one by one. This a very heart-wrenching story, and definitely not for those with a weak stomach. When the book was published in 1906, it was heavily censored and most of the worst details of human suffering were removed. What remained were the countless examples of unsanitary and plain dirty conditions in which America’s meat was prepared. The final outcome was that the book caused an uproar that culminated in the creation of the Pure Foods and Drugs Act (1906) and the eventually FDA.

The last third of the book is full of idealistic social propaganda, which makes you cringe a bit when you read it. This is why the last 100 pages took me longer to read than the rest of the book taken together. Still, the book is a very read, from both a historical and a personal perspective. More than once I’d finish reading a few chapters of the book and I was pretty depressed for the rest of the day. But overall reading it makes me appreciate much more all the little luxuries that we take for granted. Like, oh I dont know, not working from 6am till 9pm in a dirty, stinky, scorching room.

Agile Web Development with Rails
I’ve started learning Ruby on Rails a few weeks ago, and was recommended this book by a few people, and I’ve found it to be just excellent, so I’m forwarding the recommendation here. It starts out with a tutorial that covers many of the features of Rails by building a shopping cart application. The second half of the book covers most of the features in pretty excruciating details. Along the way they manage to cram in a whole lot of best practices, as well as good writing. I haven’t gone much further than reading the book yet, so we’ll see how well it prepares me for actually writing Rails applications, but it’s definitely a smooth and easy to read introduction.

More recommendations to come shortly.