In 1995, Java — marketed as “a language without boundaries” — left the labs at Sun Microsystems and took the world by storm with its object-oriented design that merged information and programming to make surfing the Web a more dynamic experience. When James Gosling, the Father of Java, demoed a virtual molecule flying across the screen when hovering his mouse over it within the Java-based WebRunner browser, the vision of the dynamic Web was put at the forefront of everyone’s mind. In essence, a revolution began.
Java (Programming Language)
- Class-based inheritance: Define classes for objects instead of the objects themselves. These classes are then extended to other classes. Objects are instances of these classes.
- Compiled language: Machine-language instructions are generated from the source code. The code has already been translated instead of needing to “interpret” or translate it on the fly.
- Thread-based concurrency: Divides work up in the hardware. Because each piece of work has its thread, and will block if it needs to (like when it’s waiting for IO), the CPU will suspend that thread and start running another that is waiting. Every time that happens there is quite a hefty context switch, including moving about 2MB of data around.
- Static typed: The type of a variable is known at compile time which leads to machine and error handling optimizations.
- Tautological: Java is verbose in where the same words are often used to define variables and other structures.
- Prototype-based inheritance: Define an object which is then extended to other objects. E.g., fruit object is extended to a banana object where the banana object has additional properties specific to the banana.
- Interpreted language: Execute instructions directly and freely, without previously compiling a program into machine-language instructions.
- Event-based concurrency: Divide work up using callbacks, an event loop, and a queue. It is non-blocking, so there is always something running on the thread. Note: There is experimental multi-threading support with Node v10 which directly competes with Java’s thread-based concurrency.
- Dynamically typed: The type is associated with runtime values and not named variables, fields, etc. The use of TypeScript changes this.
With the technical comparison aside, imagine a world where there was only one high-level programming language. Depending on your personality or bias, you may envision a scary or beautiful world. On the negative side, you might be envisioning skyrocketing unemployment rates because businesses only need one type of programmer, questioning how in the world does that get interpreted by the machine or non-performant applications based on business need. On the positive side, you might be relieved from learning new languages on a seemingly daily basis, proclaiming quicker feature creation especially in this fast-paced world we live in, or pondering the optimization of code based off a broader community of contributors.
It’s silly to think that could happen, or is it? Let’s take a step back and see how an isomorphic, universal language would benefit business, the developer and user experience, and society as a whole.
And why couldn’t a web browser be created that interprets purely one language instead of three? Or a program like Tableau be optimized to use that one universal language? After all, it all starts with the hardware.
Whether you’re an individual starting the next big startup or an employee working in a Fortune 50 enterprise, developers writing in one language helps on so many different accounts from recruiting and onboarding to team collaboration to quicker deployments, more seamless experience for both the developer and consumer, and the costs for development overall.
In conclusion, the programming world has a real problem. The nature of the business was once monolithic and siloed where languages were created for a particular purpose. Instead, the development of a sequence of languages from the low-level to the high-level should have occurred. A broader community would then optimize those sequence of languages alongside the optimization of hardware. A modular language sequence with import ability for libraries optimized for whatever hardware the code is ultimately executed on is optimal.