In this blog post, I wanted to write che classical Hello, World! getting started code in as many languages as possible.
Compiled languages (what happens before you run):
the entire code is translated into machine language before execution,
a file it generates (like .exe) so that you can run it directly,
you get all your errors upfront during the build,
once compiled, the code runs fast.
Interpreted languages (what happens while you run):
code is translated line by line during execution,
no separate build (or .exe), just write and run,
errors show up only when the code hits that specific line,
super useful for scripting and quick tests.
Paradigm Type OOP and procedural compiled
Serial . println ( " Hello, World " );
Paradigm Type procedural compiled
printf( " Hello, World! \n " ) ;
Paradigm Type OOP and procedural compiled
std::cout << " Hello, World! " << std::endl;
Console . WriteLine ( " Hello, World! " );
Paradigm Type OOP and procedural compiled
fmt . Println ( " Hello, World! " )
Paradigm Type OOP interpreted
public static void main ( String [] args ) {
System . out . println ( " Hello, World! " ) ;
Paradigm Type procedural interpreted or just-in-time compiled
Just-In-Time Compilation (JIT) is a compilation process in which code is translated from a higher-level language into machine code at runtime .
console . log ( " Hello, World! " );
Paradigm Type procedural and multiple dispatch iterpreted or just-in-time compiled
Multiple dispatch or multimethod ): a function/method can be dynamically dispatched based on the run-time (dynamic) type or some other attribute of more than one of its arguments.
Paradigm Type OO and procedural interpreted
Kotlin mainly targets the JVM (Java Virtual Machine), but also compiles to JavaScript or native code via LLVM (for native iOS apps sharing business logic with Android app).
Paradigm Type OOP and procedural interpreted
if __name__ == ' __main__ ' :
Paradigm Type OOP and procedural compiled
// https://doc.rust-lang.org/rust-by-example/hello.html
// statements here are executed when the compiled binary is called
// print text to the console
println! ( " Hello World! " );