Skip to content

Types of Languages

Course: Typescript - chapter 1

The terms strongly typed and loosely typed refer to how programming languages handle types, particularly how strict they are about type conversions and type safety.

  1. Examples - Java, C++, C, Rust
  2. Benefits -
  3. Lesser runtime errors
  4. Stricter codebase
  5. Easy to catch errors at compile time
#include <iostream>
int main() {
int number = 10;
number = "text";
return 0;
}
  1. Examples - Python, Javascript, Perl, php
  2. Benefits
  3. Easy to write code
  4. Fast to bootstrap
  5. Low learning curve
function main() {
let number = 10;
number = "text";
return number;
}

People realised that javascript is a very power language, but lacks types. Typescript was introduced as a new language to add types on top of javascript.