Fireship · @fireship

FORTRAN in 100 Seconds

Uploaded June 10, 2022 · Length 2:39

FORTRAN in 100 Seconds

Summary

A brief history and introduction to the Fortran programming language, its evolution, and basic syntax.

  • fortran
  • programming language
  • compiled language
  • imperative programming
  • history of programming

Transcript preview

The first 2 minutes of the transcript. Select a timestamp to watch that moment on YouTube.

  1. 0:00

    Fortran a compiled imperative

  2. 0:02

    programming language famous as the first

  3. 0:03

    ever highle language designed for humans

  4. 0:06

    it was developed in the 1950s at IBM by

  5. 0:08

    John bakus a guy who is too lazy to

  6. 0:10

    write assembly for the IBM 704 Mainframe

  7. 0:13

    computer the haters said it would never

  8. 0:15

    be as performant as hand-coded programs

  9. 0:17

    but by 1957 formula translator became

  10. 0:20

    the first computer language standard at

  11. 0:22

    the time computers were extremely rare

  12. 0:24

    but Fortran was a huge technical

  13. 0:25

    breakthrough because For the First Time

  14. 0:27

    Ever people outside the computer science

  15. 0:29

    realm could use a computer most

  16. 0:31

    importantly the language implemented the

  17. 0:33

    first optimizing compiler which was able

  18. 0:35

    to produce machine code just as fast as

  19. 0:37

    anything coded by hand the language has

  20. 0:38

    evolved into many different versions

  21. 0:40

    over the years and is still in use today

  22. 0:42

    primarily for heavy duty number

  23. 0:43

    crunching and scientific Computing when

  24. 0:45

    you're grandma wrote Fortran back in the

  25. 0:47

    70s she didn't have access to fancy

  26. 0:49

    tools like editors and Terminals and

  27. 0:51

    instead wrote her code on a punch card

  28. 0:53

    each card represents one line of code

  29. 0:54

    and is kept neatly in a stack where it

  30. 0:56

    can then be fed into a card reader to be

  31. 0:58

    compiled the modern developer can get

  32. 1:00

    started by installing the Fortran

  33. 1:01

    compiler then create a file ending in f

  34. 1:04

    or f95 to specify a certain version like

  35. 1:07

    Fortran 95 use the program keyword to

  36. 1:09

    give your app a name in older versions

  37. 1:11

    keywords used all caps because the shift

  38. 1:13

    key didn't exist on punch card machines

  39. 1:15

    until the 1970s declare variables by

  40. 1:17

    starting with a type followed by a name

  41. 1:19

    and optionally a default value any

  42. 1:21

    variable names that start with ik JK LMN

  43. 1:24

    will automatically be considered

  44. 1:25

    integers to disable this ancient feature

  45. 1:27

    use the implicit nun directive at the

  46. 1:29

    top use the character type to create a

  47. 1:31

    string by declaring it with a fixed

  48. 1:33

    maximum length now print that value to

  49. 1:35

    the standard output using the executable

  50. 1:37

    statement of Print Star in addition the

  51. 1:39

    dimension keyword can be used to create

  52. 1:41

    an array of numbers and multiple

  53. 1:43

    Dimensions will create a matrix just be

  54. 1:44

    careful not to allocate too much memory

  55. 1:46

    because your Apple 2 only has 4 kiloby

  56. 1:48

    of ram early versions of the language

  57. 1:50

    didn't perform fine grain memory

  58. 1:52

    management but modern versions support

  59. 1:54

    pointers that can manually allocate and

  60. 1:56

    deallocate memory but the real killer

  61. 1:58

    feature of for tram when it came out in

  62. 1:59

    the these is the ability to perform