Print "Hello World!"
In line with the tradition passed down generation after generation of programmers starting out a new programming language or just trying stuff around, the "Hello world"
program is almost a must.
From languages that do this in one line:
print "Hello World!";
to those that use classes:
public class Hello{
public static void main(String... args){
System.out.println("Hello world");
}
}
and those that simply log to console
console.log("Hello World!");
there are lots of languages out there and infinite possibilities that can be achieved using these languages. From powering a robot to the mobile apps on our phones, the operating systems various devices run on, and also the web apps (including this one) we use daily. Programming languages and computers as a whole have helped mankind achieve feats thought impossible.
Back to Hello world
, we can't possibly write this program in all languages in existence here, but you can check out leachim6's GitHub repository for Hello World
in all languages and also contribute to the repository. Instead, let's talk of how code was written by our predecessors.
First, what is programming? Programming or coding as we all know it is the process of taking an algorithm and encoding it to a computer in clear and unambiguous steps so it can be executed to perform a task. Back then, programmers wrote code in a low-level language on paper and submit them to get run, in the case of an error or bug preventing the program from executing, the programmer had to go back and find the error and repeat the process till it works.
Compilers came around and made things easier as programmers just had to write code in a high-level language (like Java and JavaScript today) and it would produce the machine code or object code equivalent of the program for the computer to execute. This abstracts a lot of pain in development as the computer understands a low-level instruction set, basically, 0's and 1's and we fare better with English-like statements.