AWK, the summer :)
Sorry, I’m addicted to puns. :) This is a note for me, you and Michele: do you want to get the sum of a set of integers? Try this one-liner: awk ‘{TOT += $0} END {print TOT}’ your_filename Use $0 if your_filename has lines with one integer each, of course you can use $another_integer if [...]
Un Ordine confessionale?
Ho inviato una mail e una lettera cartacea all’Ordine degli Ingegneri della Provincia di Torino: il testo era il seguente. Spero che qualche collega (anche cattolico) leggendo queste righe, possa esprimere pensieri simili. Il giorno 26 Novembre 2007, ho ricevuto sulla mia casella di posta elettronica, la seguente email, inviatami da iscritti@ L’Ordine intende favorire [...]
Please forgive them
Reading the referers of this website, I found that someone reached it querying a search engine for Is Nick Drake really dead? I’ve got three words to say: shame on you.
The five holy reasons
I think that I can list five main reasons to explain why good suggestions are so hard to follow (and it doesn’t matter if we are talking about the economy of a country or the settings of a GNU/Linux server). we are lazy we are unskilled we would like to make clear to everybody that [...]
Filter chains using reflection
A very common problem is submitting each object of an array to a set of tests: if a given object fails a given test, the system marks the object as “failed” without running the remaining tests. The classical solution is writing a class for the test, with a method for each test and another method [...]
Il peso della morte nel 2007
Ieri è stato un giorno molto importante per la storia dei radicali, dell’Italia e del mondo: la Terza Commissione dell’Assemblea Generale dell’Onu ha approvato la risoluzione per la Moratoria Universale della pena di morte. Giustamente, un quotidiano (che non indicherò per “proteggere i colpevoli”) ha posto la notizia a pagina dodici… ma non ci si [...]
General belief about memory_get_usage
I’ve discussed with a friend the effect on memory of assigning strings by reference (or by value) within PHP5. There is a false belief about it: I’ve just written a short script that, using memory_get_peak_usage and memory_get_usage, reports the memory used by emalloc in the following case $a = fit_the_string(); $b = fit_the_string(); $c = [...]
Termopili Valdesi
Leggendo i referer di questo sito, ho scoperto che qualcuno l’ha raggiunto interrogando un motore di ricerca per Termopili Valdesi E’ difficile trovare un episodio storico strutturalmente simile alla Battaglia delle Termopili però, immediatamente dopo aver letto questa di questa ricerca, ho pensato al Vallone degli Invincibili. Ci sono stato un paio di volte e [...]
Azure
Reading the referers of this website, I found that someone reached it querying a search engine for Adriano Celentano Azzurro and English meaning As I previously wrote, I think that “Azzurro” (Azure in English) is one of the best Italian songs of all times. The lyric was written by Paolo Conte, one of our most [...]
100 USD each
In a few years, some survivors, roaming through the ruins of our cities, could find the front page of an old daily newspaper, printed during November 2007, the day that the price of crude oil reached 100 USD/barrel… The price of the row material that keeps this civilization going has increased by more than 50 [...]
