Connecting Programs to Computers

Concepts in Computer Science

Pritesh Patel

Computer Scientist & Data Scientist for over 20 years

Bridging human to computer instructions

Animation that shows a for loop compiled to binary

Programming Languages

  • Something a human writes & gets translated into Binary
  • Intermediary

Types of Translation

  • Compilation
  • Interpretation
Concepts in Computer Science

Compiled languages: the movie production

An image that shows a recording studio as an analogy for a compiled language

Compiled Languages

  • The code is fully translated into binary (machine code) before execution.
  • This is equivalent to a movie production vs a live play
    • Script pre-written, rehearsed, filmed, and edited before showing
Concepts in Computer Science

Example compiled languages

Programming Language Logo
C Logo of the c programming language
C++ Logo of the c++ programming language
Java Logo of the Java programming language
Rust Logo of the Rust programming language
Go Logo of the Go programming language

Benefits

  • Faster performance

Drawbacks

  • Slower debug cycle
  • Platform dependent binaries
Concepts in Computer Science

Interpreted languages: the live theater

An image that shows a stage show as an analogy for an interpreted language

Interpreted Languages

  • The code is translated into binary (machine code) line-by-line during execution.
  • This is equivalent to performing a script live on stage.
    • Immediate execution
Concepts in Computer Science

Example interpreted languages

Programming Language Logo
Python Logo of the Python programming language
Javascript Logo of the javascript programming language
Ruby Logo of the Ruby programming language
php Logo of the php programming language
R Logo of the R programming language

Benefits

  • Flexibility and fast iteration

Drawbacks

  • Can run slower
Concepts in Computer Science

Let's practice!

Concepts in Computer Science

Preparing Video For Download...