Friday, 21 December 2012

Outsourcing to North Korea

So…you can outsource IT development to North Korea. From the website:

In addition to the accessible skill level Nosotek was set-up in DPRK because IP secrecy and minimum employee churn rate are structurally guaranteed.

Monday, 10 December 2012

Phrase of the Day: "The Brazilian Straddle"

It is not as sexual as you may suspect:

for a more technical but very entertaining read: "Trading and Exhanges" by Larry Harris. eg in this book I learnt about "the Brazilian straddle" options position: a naked short option position hedged with a one way ticket to Brazil. (in case the bet goes against you)

The natural followup question: how does a person already living in Brazil make a Brazilian straddle?

Wednesday, 7 November 2012

The Technology is Not Quite There Yet

I'm taking a flight tomorrow. I put the details in my Google Calendar.

A reminder appeared 24 hours in advance on my iPhone. And on my iPad. And on my office iMac. And on my home MacBook Pro. And twice in my Google Mail. And OS X's Mail program, which I don't normally use, opened on both computers.

One reminder would be sufficient.


Friday, 2 November 2012

Yakuza: The Worst of the the Worst

Goroawase is a kind of wordplay using words based on the sound of numbers. A famous example is the word for the Japanese mafia, yakuza, which comes from yattsu (eight), kyu (nine), san (three). Hanafuda is a traditional Japanese card game where the worst possible hand combination consists of an eight, a nine and a three. The yakuza are the worst of the worst.

That's from an interview with my friend, writer Aidan Doyle.

Friday, 21 September 2012

Apple maps have changed the name of my street

I installed iOS 6 today on my iPad and iPhone. The "Maps" app is no longer "Google Maps"; it is now "Apple Maps". Fine by me, except all the street names here in Barcelona have the actual Catalan names replaced with Spanish equivalents.

For example, my street is no longer "Carrer de Bailén" but is "Calle de Bailén". The nearest cross street is not "Carrer de Córsega" but is "Calle de Córcega".

My office seems to have moved from "Passeig d'Amunt" to "Paseo Amunt".

This is somewhat inconvenient for me. For the native residents of Barcelona it is probably insulting.

Wednesday, 19 September 2012

The Best Objective-C IDE is written in...

…not Objective-C.

I'm working on a new mini-project, SeeingStars. This show real time poker odds for PokerStars. I'm writing it in Objective-C, as an opportunity to improve my rather basic Objective-C skills. I'm using AppCode, an Objective-C IDE from JetBrains which makes programming in Objective-C a more pleasant experience, compared to Apple's own, free Objective-C IDE Xcode.

And the ironic thing? AppCode is written in Java.

Monday, 3 September 2012

IntelliJ IDEA, PyCharm, RubyMine, AppCode 50% off

If you are a believer in using damn fine tools in your work as a software craftsperson, this is an offer you don't want to miss. JetBrains is offering 50% off their excellent programming tools

Friday, 17 August 2012

Lebanese Uniqueness

Only in Lebanon have I heard of families having military wings:

in reference to ... the kidnapping of the Syrian nationals in Lebanon by the Meqdad family military wing.

Saturday, 28 July 2012

iPhone Fact of the Day

According to this article in Vanity Fair chronicling Microsoft's "Lost Decade": the iPhone brings in more revenue than the entirety of Microsoft.

No, really.

One Apple product, something that didn’t exist five years ago, has higher sales than everything Microsoft has to offer. More than Windows, Office, Xbox, Bing, Windows Phone, and every other product that Microsoft has created since 1975. In the quarter ended March 31, 2012, iPhone had sales of $22.7 billion; Microsoft Corporation, $17.4 billion.

Friday, 20 July 2012

Quote of the Day

From a report on the cost of arms in Syria's almost civil war:

 “We had M-16s but we only had 100 bullets for them,” he said, smiling ruefully. “So the M-16 became useless. We are using it as a stick.”


Friday, 13 July 2012

How to Increase Tips

In Konka cafe in Tbilisi, Georgia, the staff wear these t-shirts:

IMG 0814

Even though the cafe already added 10% service charge to the bill, I still felt compelled to tip. I wonder if the cafe has performed tests with and without these t-shirts? I suspect tips are significantly higher with the t-shirts.

 The software mogul in me wants to perform A/B testing to determine the difference.

Thursday, 12 July 2012

Sentence of the Day

George R.R. Martin is not your bitch.

That's from Neil Gaiman on Entitlement Issues.

Thermonuclear destruction caused by a baseball

What would happen if you tried to hit a baseball pitched at 90% the speed of light?. An excerpt:

The ball is going so fast that everything else is practically stationary. Even the molecules in the air are stationary. Air molecules vibrate back and forth at a few hundred miles per hour, but the ball is moving through them at 600 million miles per hour. This means that as far as the ball is concerned, they’re just hanging there, frozen.

I learnt a lot. More than I ever did in a lecture when I studied undergraduate physics.

Sunday, 3 June 2012

Quote of the Day

the Death Star is a very antiquated vision of what evil will look like. Evil will come in stylish, Steve Jobs-inspired designs.

That's from an interview with Nobel-prize winning economist Paul Krugman.

Monday, 14 May 2012

How Wikipedia has altered my expectations

I was reading an article on Der Spiegel. It claims, 

But others argue that the state is simply supporting bad employment practices.

I implicitly added a small [who?] text after the sentence.

Wednesday, 9 May 2012

Smoking and the Nazi War on Cancer

Wow. If this is accurate, German scientists under the Nazi regime definitively linked smoking to cancer and initiated a large-scale anti-smoking campaign.

I now begin to understand how companies I worked for in Germany still had optional smoking offices. That Nazi spectre looms large, and only now are the last people with strong memories of living under the Nazis dying off. 

Friday, 4 May 2012

Using Ruby for iOS applications

This is big news for iPad and iPhone developers. The headline says it all:

Ruby + iOS = Super awesome!
Are you fed up with Objective-C? Now, you can build iOS apps with Ruby (mruby)!.

I'd like to see a Python equivalent one day. The pedigree is good; it is from the creator of MacRuby.

Wednesday, 25 April 2012

Embedding a OpenJDK 7 Java JRE in Poker Copilot

As of an upcoming new OS X version, Apple's Java team are encouraging Java developers to embed a Java JRE in our applications. Unfortunately Java on the Mac is not quite ready for us to do this. Nevertheless I'm doing my best to prepare for this, so that I can give helpful feedback on problems to Oracle and Apple in time.

Here's how I currently got an embedded JRE into Poker Copilot:

1) I downloaded and installed Oracle JDK7u4 Mac OS X Port Developer Preview.

2) I copied the JRE folder from the developer preview. I copied from:



a folder in my app I called ./jre

I launched my application using this command line: (note that this is in a dev environment not in a OS X app bundle, hence the hard-coded path to idea_rt.jar and my app classes not being jar'ed)

jre/bin/java -Dapple.laf.useScreenMenuBar=true "-Xdock:name=Poker Copilot" -Xdock:icon=../creative/512icn.png -Xmx768m -classpath "jre/lib/charsets.jar:jre/lib/jce.jar:jre/lib/jfr.jar:jre/lib/jfxrt.jar:jre/lib/JObjC.jar:jre/lib/jsse.jar:jre/lib/management-agent.jar:jre/lib/resources.jar:jre/lib/rt.jar:jre/lib/ext/dnsns.jar:jre/lib/ext/localedata.jar:jre/lib/ext/sunec.jar:jre/lib/ext/sunjce_provider.jar:jre/lib/ext/sunpkcs11.jar:jre/lib/ext/zipfs.jar:out/production/DesktopApp:lib/*:/Applications/IntelliJ IDEA" com.barbarysoftware.pokercopilot.Launcher

For clarity, here's same command line broken into separate lines:

jre/bin/java -Dapple.laf.useScreenMenuBar=true "-Xdock:name=Poker Copilot" -Xdock:icon=../creative/512icn.png -Xmx768m -classpath "jre/lib/charsets.jar:jre/lib/jce.jar:jre/lib/jfr.jar:jre/lib/jfxrt.jar:jre/lib/JObjC.jar:jre/lib/jsse.jar:jre/lib/management-agent.jar:jre/lib/resources.jar:jre/lib/rt.jar:jre/lib/ext/dnsns.jar:jre/lib/ext/localedata.jar:jre/lib/ext/sunec.jar:jre/lib/ext/sunjce_provider.jar:jre/lib/ext/sunpkcs11.jar:jre/lib/ext/zipfs.jar:out/production/DesktopApp:lib/*:/Applications/IntelliJ IDEA" com.barbarysoftware.pokercopilot.Launcher

3) It runs! There are a couple of rendering issues which are known by the Oracle/Apple team working on the OpenJDK7 Mac OS X Port. Namely, progress bars don't progress, unified toolbars don't unify, and window resizing is graphically not good. But otherwise, it runs!

For further clarity: this is the list of files in the embedded JRE I have on my class path:


Some are most likely not needed.

Now the big issue: the JRE is adding 55 MB to my app bundle size. That's after I zip the JRE folder. I need to determine which files I can safely remove from the JRE. But even then, the biggest file is the non-optional rt.jar, which compresses to 21 MB.


German Culture...

…how I miss you.

The Beard and Moustache Championships:

Sunday, 22 April 2012

Sentences of the Day

The first sentence is a marvel. The second is amusing:

I was slightly surprised when a friend pointed out there are three books in Amazon's "Books › Fiction › Erotica › Global Warming & Climate Change" section. I thought there would be more.

Read the whole article here.

Thursday, 19 April 2012

Google and Flight Codes

Google is still doing some great things. My friend is arriving today at Barcelona airport. I wanted to make sure her flight was on time, so I entered the flight code into Google. Here's what I got:

Screen Shot 2012 04 19 at 2 01 34 PM

Perfect. Exactly the information I needed. Time to arrival and the arrival terminal.



Wednesday, 18 April 2012

Strange Maps

is my new favourite blog. And book.

He also writes fascinating detailed articles about cartographical oddities in the NY Times.

iPad Development or Reading Science Fiction

I'm experimenting with my first iPad app, a simple Hello World app. The amount of obscure vocabulary, verging on meaningless is like the reading the first few pages of a hardcore science fiction novel. My favourite: I need to create a "provisioning profile", which I partly store in the "portal". The full phrase: "First, create a distribution provisioning profile using iOS Provisioning Portal".

These words and terms are introduced with no definition. One's eyes must glaze over, hoping that the meanings of the terms become clear later.

Thursday, 5 April 2012

iPad Apps, polished and raw

I've had my iPad almost a week, and I've been trying and buying several apps to get a feel for what's possible on the device.

Usually the apps that are recommended or grab my attention and polished. The interface, the appearance, the transitions all are top class.

One app in particular though, has a clumsy, unpolished user interface. Yet I've been using that app often. It's the NY TImes Crosswords app. You see, I'm a crossword fanatic, living in a country where my mother tongue, English, is a foreign language. So I'm deprived of good crosswords I can do. I'm willing to the accept the raw user interface because I want what the app can offer me so badly. To some degree I guess they have a monopoly on NY Times crosswords.


Wednesday, 4 April 2012

Google Going Backwards?

I try not to rant or be negative when blogging…but…in recent months i've been puzzled by Google. I use many of their sites daily. Those sites seemed to keep improving. But I've been noticing some going backwards. Becoming harder to use. Becoming cluttered, confusing, and surprising. The three in particular that really get to me:

* Google Mail

* Google Reader

* Google Groups

* Google Search (search for 'Foobar', then click on the "images" link in the top menu, then "Maps", then "News". Images and Maps keep the search phrase, News doesn't. Puzzling. This behaviour differs on the left-hand menu. Damn puzzling.)

I realise these are free offerings, so I might have no right to complain. I agree. I just can't figure out why these web sites are getting worse. Especially given that they are most likely widely used internally at Google. Surely people at Google are also frustrated by the changes.

Monday, 2 April 2012

My Thoughts on Developing Apps for iPad

I purchased my first iPad last week. I bought it for the purpose of developing iPad apps. Why?

In the last three months of 2011, Apple sold 15.4 million iPads. A lot? Yes. Current trend? Upwards. Way upwards.

Buying apps on an iPad is mostly an low-friction impulse purchase.

An iPad is expensive. Someone who can afford an iPad is likely to have a reasonably high level of disposable income.

There are many iPad apps already, the vast majority of which earn little to no money. This is because developing a simple iPad is just challenging enough for a software developer with a new iPad to enjoy, while being just easy enough to complete. However these developers usually don't realise that running a successful business involves more than just realising a simple app, then sitting back sipping cocktails on a Caribbean beach. A successful business requires skill, persistence, and luck.

My feeling is that if I create some apps that appeal to people, then listen to feedback, and improve, improve, improve, this can be a viable business. Does it require some luck? Indeed. But it also requires business skills, software development skills, an ability and willingness to continually learn, and the secret ingredient: persistence.




This XKCD is clever - read the 'mouseover' text then try increasing/decreasing your browser window size, or zoom in and out.

Although as a speaker of German as a foreign language, I translate "Umwelt" simply as "environment".

Thursday, 29 March 2012

Google Earth's Dali-esque Bridges

When Google Earth goes 3D, it doesn't handle bridges too well...

Two Ways to Stop Niagara Falls

The site in in French, but the photos are readable in any language.

The first time was when it was cold enough in 1911 to freeze the falls.

The second time was in 1969 when the US Army's Engineer Corps diverted the water to check the erosion.


Wednesday, 14 March 2012

iPhone Apps I recommend #4

iPhones come with a weather app. There are probably many free and paid alternatives. However I like WeatherPro. It has sunset time, sunrise time, moon phase, 3-hourly forecasts for rain and sun, and multiple locations.


Friday, 9 March 2012

iPhone Apps I recommend: #3

When iPhone apps first became available I dreamt of a new type of digital guidebook. You would carry it in your iPhone and it would use the assorted features of your iPhone to be more helpful than paper guidebooks. It could be more up-to-date, released more often, and available per city.

The first attempts to do this were dreadful. By now, some years later, we've got the excellent TimeOut travel guide apps. I use the TimeOut Barcelona app often, even though I am not a tourist but a resident. Want to find a recommended cafe within a few minutes walk of your current location? It does that. Offline maps? It has that too. Reviewed restaurants, night life, museums, and hotels are all there.

At the time of writing there are TimeOut apps for 16 cities. I hope the model is widely copied.


Sunday, 4 March 2012

iPhone Apps I recommend: #2

You know those times you are staying in a mountain cabin with friends, and you go outside at night? It is so much darker than city nights and you gaze together at the billions of stars. Then you try to show off to each other, by naming constellations. Everybody knows Orion, but otherwise you are mostly just guessing.

That's why I love Star Chart. Using the GPS in your phone and other sensors, it can tell where you are and where the phone is facing. So point the phone towards the star, planet, or constellation you want to identify, and it tells you all. Mountain cabins often lack mobile phone reception, so gratefully this app works offline. Not only is it useful, it is beautiful.





Saturday, 3 March 2012

iPhone Apps I recommend: #1

I live in Spain. I don't yet have data on my iPhone in Spain. Sometimes I drive around Spain and want a quality low-cost GPS/Navigation app for my phone that doesn't require live Internet connection.

I've tried a few options and settled on GPS Navigation 2 as the best of the bunch. It is cheap, it has offline mode, it works well, and you can buy data on a country-by-country basis. Or on a continent-by-continent basis.



Thursday, 23 February 2012

Online Businesses in Greek and Stool Samples

According to this article, Greece is a particularly difficult place to start an online business:

Antonopoulos and his partners spent hours collecting papers from tax offices, the Athens Chamber of Commerce and Industry, the municipal service where the company is based, the health inspector’s office, the fire department and banks. At the health department, they were told that all the shareholders of the company would have to provide chest X-rays, and, in the most surreal demand of all, stool samples.

For the sake of all that is decent, I really hope this is an error in translation or understanding, or a plain exaggeration. Thank goodness I didn't start Poker Copilot in Greece.

Tuesday, 7 February 2012

What I'm Cooking for Dinner Tonight



  • 1 tablespoon olive oil
  • 2 cloves garlic (crushed/chopped)
  • 1 medium onion (diced)
  • 1- 2 tablespoons curry powder, to taste
  • Salt, to taste
  • 1 cup small red lentils
  • 3 cups water
  • 2-3 bay leaves, to taste
  • 1 cinnamon stick
  • 1 tin tomatoes, (chopped)
  • 1/4 cup coconut milk
  • 2 tablespoons lemon juice


  1. In a large saucepan, saute garlic til fragrant.
  2. Add onions and cook until they begin to soften.
  3. Add curry powder and salt, to taste, and cook over medium heat til mixture begins to brown.
  4. Add lentils and stir for a minute or so before adding water, the bay leaves and cinnamon stick. Bring to boil, then turn heat down very low and simmer for 20minutes, stirring occasionally.
  5. Add chopped tomatoes, and simmer a further 10minutes, until thick. The lentils should be soft and the consistency just liquid enough to pour.
  6. Add coconut milk and lemon juice. Stir through, and remove from heat.

Serve over rice with lime pickle and mango chutney.

Thursday, 2 February 2012

Expensive creation of a Java instance

Execute this code in your Java program:

SimpleDateFormat df = new SimpleDateFormat();

Here are the consequences:

  • 55 distinct methods are called a total of 123 times
  • 44 new instances of objects are created

That is one badly-designed class. And that's before considering the non-thread-safety of SimpleDateFormat that leads it to be probably the #1 cause of concurrency issues in Java programs. And which prevents reusing one instance across an entire application.

I sourced this here.


Friday, 27 January 2012

Mega-man: The fast, fabulous, fraudulent life of Megaupload's Kim Dotcom

There is a fascinating article on Kim Dotcom on ars technica:

Flush with at least some cash, Schmitz was quick to burn some of it by waving his own particular brand of freak flag. He hired a German centerfold, a collection of other actors, a film crew, and fast car aficionados for a self-produced film called Kimble Goes Monaco—a road movie about a lavish trip to Monaco, including a cruise on a rented yacht. The movie was punctuated with Schmitz playing with expensive toys, and featured a bizarre Bill-Gates-is-spying-on-me subplot.

Although it sounds like guy has a serious deficiency in the morals department, he can't be accused of half-living his life.


Pink Monopoly…or Marketers get Creative

When I heard of Pink Monopoly I thought it was a joke or a euphemism. But no, it really exists, and the major marketing ploy seems to be…that it is pink:

Product Features

  • Special girl's edition
  • Packaged in keepsake storage box with removable tray and non-glass mirrored insert
  • Pink gameboard and dice with unique properties to buy such as spas and jewellery stores
  • Boutiques and malls instead of houses and hotels
  • Instant Message and Text Message cards instead of Chance and Community Chest


Tuesday, 24 January 2012

A Brief, Incomplete, and Mostly Wrong History of Programming Languages

Read it here.

In spite of its lack of popularity, LISP (now "Lisp" or sometimes "Arc") remains an influential language in "key algorithmic techniques such as recursion and condescension"


Saturday, 21 January 2012

Learning to Program for the iPhone: Hello World

There are a lot of new concepts and terminology to learn when programming for the iPhone for the first time. I've worked my way a little through Apple's "Hello World" tutorial, and I achieved simply that: a program that displays "Hello World" and runs in the iPhone simulator:

Screen Shot 2012 01 21 at 7 12 17 PM

Nothing to set the world on fire yet.


Friday, 20 January 2012

On Not Making Plans

I like this:

This new year, do something different: stop setting goals.


Most good things happen without a plan: friendships, falling in love, finding a job, and so on. If you want to make your new year count, you’ll need to be intentional — not by setting goals, but by making space in your life for what really matters.

Not making plans is how I live these days.



Monday, 16 January 2012

My First iPhone App in the Next 7 Days?

This week I'm doing some rather tedious non-programming tasks on my main product, Poker Copilot. So I need something else to exercise my mind. The goal I've set: my first iPhone app. I'll aim for daily progress reports over the next seven days.

I know some Objective-C and Cocoa; I'm well-acquainted with many iPhone apps (Angry Birds, cough, cough); I have an idea for a non-novel, simple iPhone app. I think I can do this.


Monday, 9 January 2012

German Ingenuity and Zombies

Those Germans...

"Of course I'll only use it on zombies, never on human beings. I swear….[pause with sardonic grin]…"

Sunday, 8 January 2012

A Little Less of that Red Earth, Lifeguards and Kangaroo Stuff

From Tyler Brûlé's praise of the Antipodean way

Both Melbourne and Sydney offer so much on the culinary front alone that you could do with marketing these cities with dedicated campaigns and do a little less of that red earth, lifeguards and kangaroo stuff.