Hexlet doesn not really work properly in your browser, because it is pretty old. Please, upgrade.

Intro to Programming

What are computers really? Do they speak programming languages? Is it hard to write your own programs? This course answers these and many other questions and explores the nature of computers, code and some fascinating ideas that allowed us to create modern computers, mobile phones, internet and, you know, pretty much everything we rely on every day.


  • 1

    What's a computer anyway?

    Goal: Ask and try to answer some simple, but important questions: what's a computer anyway? Is it smart? Does it speak programming languages?

    theory (05:32)  
  • 2

    Human and computer languages

    Goal: Explore the idea os programming languages and figure out what language should you strat with.

    theory (05:43)  
  • 3

    Writing your first program

    Goal: Write your very first program in JavaScript and get to know the Hexlet's virtual computer that you'll be working in during the course.

    theory (05:10)   quiz   exercise  
  • 4

    Constants and E=mc2

    Goal: Learn about basic math in JavaScript, work with numbers and constants to calculate the total energy of your body using Einstein's famous formula.

    theory (05:04)   quiz   exercise  
  • 5

    Making functions — black boxes

    Goal: Learn about functions — the building blocks of programs, how to create and run functions.

    theory (05:11)   quiz   exercise  
  • 6

    IF conditions and programs making decisions

    Goal: Learn about conditions and boolean algebra, the mechanism that allows programs do one thing or do another thing based on some information.

    theory (05:43)   quiz   exercise  
  • 7

    Oh, no, errors! And dealing with them

    Goal: Understand how errors arise in computer programs, how to recognize them and fix them.

    theory (07:54)   quiz   exercise  
  • 8

    Recursion: when function calls itself

    Goal: Wrap your head around one very powerful and extremely important concept in programming — recursion.

    theory (06:31)   quiz   exercise  
  • 9

    Iterative process and not being lazy

    Goal: Recursion is great, but the plain recursive process is not too efficient. Learn about an alternative way to compute recursively.

    theory (06:05)   quiz   exercise  
  • 10

    Variables and repetitions

    Goal: Learn about variables and a way of repeating code with loops. Understand the important distinction between declarative and imperative programming.

    theory (07:14)   quiz   exercise  
  • 11


    Goal: Get to know text data, strings and learn to manipulate them: glue together or take apart.

    theory (05:27)   quiz   exercise  
  • 12

    Mutators and for loop

    Goal: Learn some arithmetic shortcuts to quickly change the values of variables, and get to know the for loop — another way to create repeating code.

    theory (02:36)   quiz   exercise  
  • 13

    Testing code with other code

    Goal: Understand the idea of testing code — writing code that checks the behavior of other code, look at some examples and write your own tests

    theory (05:19)   quiz   exercise  
  • 14

    Dividing code into modules

    Goal: Learn about dividing code into meaningful and reusable modules.

    theory (05:35)   quiz   exercise  
  • 15

    Expressions vs. Statements

    Goal: Understand the important distinction: expressions vs. statements in JavaScript. And learn how this knowledge will help you.

    theory (04:38)   quiz  
  • 16

    Environment, scope and closures

    Goal: Understand how and why isolated environments are created in JS, what scoping is and how cool are closures.

    theory (07:39)   quiz   exercise  
  • 17

    Typing: dynamic vs. static and weak vs strong

    Goal: Learn about types in JavaScript, and understand the difference between dynamic and static typing and weak and strong typing.

    theory (07:22)   quiz   exercise  
  • 18

    Pure functions and side effects

    Goal: Explore the idea of determinism, side effects, and purity in functions. Get to know the beauty of pure functions.

    theory (06:55)   quiz   exercise  
  • Course completed

  • Challenges

    We recommend you to work on these challenges after completing the course. They will help you obtain more experience in programming and strengthen new skill.

    # Challenge Success rate
    1 Formatted time 91%
    2 DNA to RNA 93%
    3 Perfect numbers 93%
    4 Angle Difference 89%
    5 Happy ticket 93%
    6 Sum of square 95%
    7 Palindrome 87%