Archive > May 2010

On Beer

31 May 2010 » In Beer, Me » 3 Comments

Hi, my name is Andrei and I am a beer enthusiast.
To some of you this may not be news, but beer is something that has become a significant part of my life during the last couple of years. That is not to say that I didn’t drink beer before – I did, but somewhat indiscriminately and without paying much attention to the actual product. And while I do enjoy other fine adult beverages, such as wine, bourbon, whisky, gin, and well-crafted cocktails, beer is what I feel passionate about and I finally want to start writing a bit about it, on this blog, for now.
Beer is the world’s oldest and most widely consumed alcoholic beverage and the third most popular drink overall after water and tea. Many anthropologists and historians believe that beer is what made early hunter-gatherers finally settle down and become sedentary farmers, because well, they needed barley to brew it, so one can say that beer was one of the driving forces behind the rise of civilization. Moreover, most fresh water wasn’t exactly safe to drink back then and beer provided both hydration and sustenance.
Beer has more styles and varieties than any other alcoholic beverage, and though almost all beer is made using the same 4 ingredients (water, barley, hops, and yeast), the sheer number of additional ingredients that can be used to brew beer and the creativity that goes into the process can put almost everything else to shame. Despite this, there is still a widely spread perception that beer is that pale, cold, “subtly flavored” beverage that is marketed by the giant companies collectively known in the brewing circles as BMC. I’ll let you guess what that stands for. Thankfully, there is a thriving craft brewing industry both in the United States and abroad now, and beer is finally starting to be treated with respect.
About a year and half ago I got into homebrewing, thanks to the efforts of Brien Wankel and especially Sean Coates, who has been instrumental in answering a bajillion questions I had when getting started. I never thought that I could actually make beer myself, but after reading the online version of How to Brew by John Palmer, I was immediately fascinated by how easy and yet how sophisiticated the brewing process can be. The more advanced part of it has to deal with biochemistry, thermodynamics, fluid dynamics, and even metallurgy and this appealed to the geek in me. I bought the starter kit from MoreBeer and made my first batch, which was a Best Bitter English-style ale. When I opened a bottle 4 weeks later and found that not only was it not bad, but actually pretty drinkable, I knew that I was hooked. Since then I’ve brewed about once a month, exploring various techniques and styles. I’ve also sent some of my beers to competitions and even won a 3rd place in the American Amber category at Puget Sound Pro-Am last year.
Crafting a beverage that can be enjoyed by yourself and others is a great feeling, and I hope to share more about it in the coming posts. Additionally, I plan to review various beers and write about the beer industry, events, places to find good beer and hopefully much more.

Regex Clinic on Slideshare

03 May 2010 » In PHP, Talks » 5 Comments

Back in 2004, I submitted a proposal to the only PHP conference ever to have taken place aboard a cruise ship. Yes, the infamous PHP Cruise (“Do we all know each other?”). The talk was about regular expressions and their usage in PHP. I wrote the original version in PowerPoint, but when I boarded the ship and saw Keynote 1.0 on someone’s Powerbook, I was hooked and had to port all the slides to Keynote right then and there.
Well, the talk – and the cruise – went well, and since then Andrei’s Regex Clinic has grown and shrunk in size depending on which conference I was giving it at and how much time was allotted. I considered retiring the talk several times, because surely people should know how to use regular expressions by now, but whenever I give it there is a roomful of people wanting to know what (?>=foo) does. And as much as I try, I always run out of time trying to cover everything from the basics to more advanced usage.
I feel that the slides are pretty polished by now and it’s better if people can read them at a comfortable pace, so the whole tutorial-sized presentation is now available on Slideshare. I omitted the section that covers PHP’s regular expression API, because it already has great online documentation. Otherwise, go forth and read about look-ahead assertions and recursive matching.