Wednesday, November 21, 2007

Basic Math

I can't believe what happened to me last night. I don't know what caused it but I suspect the framework I'm using at work is to blame.

I went to CDR King to buy some blank dvds and asked how much would twenty-five of those cost me. The girl at the counter said they were priced at twelve pesos each so I struggled to calculate it and ended up with six hundred pesos. Damn it. Counter-girl then told me they didn't have any stack less than fifty pieces so I told her to go ahead and get them for me.

I held three five-hundred peso bills as the girl rang up my order because I thought I was going to shell out a thousand and two hundred for the stuff. Everything was totaled and my bill was at six hundred pesos. I embarrassingly pocketed my extra bill.

Tuesday, November 20, 2007

Neat Questions

From necramirez:

questions sa client (U.S.) interview via phone:

CompSci questions!

1) Given an array of integers of length N, you know that the values are unique and belong to the range 0..N, where one number is missing (0..N is N+1 numbers). Provide a solution to determine the missing number and what is its running time.

2) Given a 2xN grid, provide a solution to determine the number of possible ways to arrange 1x2 tiles to cover the entire grid.

3) Design Problem: You are able to accept different forms of input (XML via Web Service, plain string, XML via HTTP request) and should likewise be able to output in different formats (HTTP Response, Web Service Response, e-mail). Describe how you will set-up the application such that it will be easy to add new forms of input and output.


I will try and solve these later when I have the time. In the meantime, feel free to post your solutions.

Thursday, November 15, 2007

Interviewing Developers

Joel Spolsky writes a very interesting guide (The Guerrilla Guide to Interviewing (version 3.0)) on how to interview candidates properly to find out the best hire for a developer position. I've only recently been able to test applicants for our company but only as a peer level test. I haven't interviewed any of them other than viewed their resumes and the results of the interviews of managers.

Most of the candidates failed the Java and SQL proficiency tests but our company is desperate so I made up some small problems for them to try and solve. I made them write a program that would use a loop to display the following:

*
**
***
****
*****

I then asked them to rewrite that loop to display:

*****
 ****
  ***
   **
    *

Next, they were asked to take the last triangle and count the number of asterisks per line. Lastly, they were asked to sort the number of asterisks into ascending order.

I'm very surprised that no one was able to ace the exam and only two had some competent solutions to the first and third problems. Those two might have just been copying each other's work.

We ended up hiring one of the two who were able to answer some of the test. I'm hoping it's not a bad decision.

Thursday, November 8, 2007

Nodame Cantabile


It's a live Japanese Television series. It's funny and awesome. Check it out.

Tuesday, November 6, 2007

The Approaching Storm

Manila Bay under "Kabayan" Tropical Storm.

Ye ole pen case thingy

... out of old diskettes.

Tuesday, October 30, 2007

Fairy Tales and Their Dark Pasts


I'm a subscriber to www.straightdope.com and I'm amazed what Cecil, the author can dig up. This piece about fairy tales and their earlier and darker versions just give me the creeps. I mean, necrophilia and cannibalism? Whoa. Pic from the article.

Internet Explorer

Alright, which one of you guys accessed my blog using IE? I feel so dirty.

Friday, October 26, 2007

Manila Bay


From Marina.

Holloween


SM Centerpoint Hollow's Eve Toys.

Thursday, October 25, 2007

@#$%%^*@#@#$!!!

ABS-CBN Interactive: Arroyo Pardons Erap

There is no justice here in the Philippines.

There are frameworks and there are frameworks

I just want to rant about the current framework I'm using. I'm not that experienced in Struts or Hibernate or any other framework so I really can't compare but the framework I'm currently using is so shitty it makes me want to just give up and die.
To add a new DOM element you have to revamp everything. It's not just attaching a new object, you have to rewrite all data validation rules that happen to affect that object. I wish I could just attach it to the DOM then specify some rules. What happens is I attach it then give some dos and don'ts for the data then I check what other stuff happen to be affected. Argh, I think this rant is going to be spread out in a lot more posts. I can't write coherently what I think is wrong and what should be done to correct it.

Monday, October 1, 2007