Category: Geeky side of life

18 Feb

Top 10 music for programming

57_Brugge_Belfort_Interno

For programming one needs silence to concentrate at the problem at hand. But comes a time (often) when one has to go in auto mode, and have the hands write the ideas accumulated at the time. Good music is the best thing to let them go, and it must be non-boring, lengthy enough to avoid having to switch back and forth, with the right level of darkness and, above all, top quality. The rule I followed is 1 per author, if an author has more than one submission, they share the same slot (and most, share). So, from bottom to top: 10 – Dido – Life for Rent, No Angel For some reason when programming sad, melancholic¬† music feels better than a beach Boys album would, probably because I want my brain to be kidnapped by the music while the hands write like an automaton, and not my brain to start . Life for Rent has fewer good tracks than No Angel, but I’ve listened to No Angel literally too much and it’s starting to get boring. 9 – Dire Straits – Love over Gold Dire Straits are able to reap a 9th place in this list, and it’s strange. Their music don’t fit the theme, and it’s generally not good to code with; you can’t concentrate with Twisting By The Pool. Still Love over Gold is a strange beast, and they are able to get on the list with just two songs of a single album of all their life. The first two of [...]

(more...)

01 Feb

A smarter but not smartest greedy algorithm for hotel bookings

hotel

Doing homework for my university studies, I stumbled upon the problem of having a somewhat smart logic for hotel bookings. The assignment was to build a model-2 jsp/servlet based website for bookings of a generic hotel chain; the required booking facilities were simple but I wanted to do something smarter, and solve the problem in a satisfactory way. Let’s say that you are eager to go to Sidney between the 29th Jan and 5th of Feb.. because – well, any reason you want to be there in that period. What bothers me is that most booking facilities just check for a whole availability – a single room available for the entire period. Now, if I really want to go to Sidney, and I’m already willing to take 12+ hours of plane to go there, renew the passport, fight spiders, etc., probably having to change the room at the mid of my stay there is the least of the problems – specially if the alternative is not going to Sidney at all. Now, apart from the fact that this is a stupid example because I would never want to go to Sidney because there are some of the worst (1) spiders (2) of the world(3) there,¬† the problem was interesting to solve and the solution happened to me while walking towards home, listening to Alesha Dixon – this to justify the non-optimality of the algorithm. (The rest of the project was built over Miles Davis prestige recordings I received as a present for Christmas… much better [...]

(more...)

16 Jun

ScummVM DS Patches – version 4

(Quick download links : .NDS builds or .DS.GBA builds, modified sources here, SourceForge patches here) I’ve patched ScummVM DS once again.. See here for more details, versioning, how, why, what, which, who.. Changes in ScummVM/DS 0.11.1.MMP4 (.NDS builds or .DS.GBA builds): All previous changes Fixed a bug with mouse icon Attempt to show mouse cursor on upper screen also when LCDs are swapped (sometimes it fails to be in the correct position but it covers most cases). Be vigilant.

(more...)