Most people who know me know that I hate Macs. Unfortunately, I have to use them for work purposes (and it seems, I am using it even for this very blog for the time being, as my PC is on the cusp of giving up the ghost so have to wait until I can muster up enough £££ to get a new one).
Anyway, during a coding session, I noticed a peculiar similarity between Java and the Latin Mass (in the Catholic Church). Ok, for those who don’t know, every program that you run on a computer has to be programmed by someone or a group of people somewhere; it doesn’t just fall like manna from Heaven 😉 . Programs are programmed in different languages – some are programmed in C++, others in C#, others in Python, and so on and so forth.
This might sound like gobbledygook until you imagine it is much like travelling the world and going to Mass in each country and hearing the Mass said in different languages – some are in English, others in French, others in Spanish, Zulu, etc. This, of course, is problematic: most of the world are not gifted polyglots and so understanding what is said at a Mass said in a different language is problematic. The same can be said about computer languages – because each computer/phone/tablet (more specifically, each computer’s processor) understands a program slightly differently, this means that a programmer would have to tailor a program specific to that computer’s processor for it to understood in the same way universally. There are hundreds of thousands of processors so this is virtually impossible. In some cases, it would be impossible for it to be understood by the processor (what is termed as ‘lacking portability’, portability meaning how easily a program can be used/transferred on different platforms).
Java solves this by using what is called a ‘Virtual Machine’. This means that it translates the code of a program written by a programmer into what is called ‘bytecode’ – this translation being done behind the scenes with the help of a compiler – with the end result being that a program coded in Java is understood by all kinds of processors in much the same way; in the same way that the Latin Mass, by being said in Latin, offers a universal standard. Your ‘Dominus Vobiscum’ is the same in London as in Paris as in Rio de Janeiro and as in Santiago. This means that a priest from Brazil could offer a Mass in England with no real loss of understanding by the faithful present at the Mass.
Yet lest I be accused of being a Latin Mass fanatic, the downside of a Virtual Machine is that it results in a loss of speed – understandably so, the Virtual Machine is effectively an intermediary between the code by the programmer and the underlying hardware of the computer. Much the same could be said about the Latin Mass: whilst its advantage is in allowing people to understand it wherever they go, this comes at the expense that the faithful cannot understand it with as much ease as they would in their own native language.