Programming - crash course

Intro


In this course, you will learn the most important parts in computer programming:

  • Strings
  • Variables
  • Functions
  • If-statements
  • While-loops


This is the main “lego-bricks” in all programming. After this course you will be ready to make some real magic!

We will use Javascript, which is one of the most popular programming languages on the planet.



Strings


Open Sublime (or any other texteditor like Notepad++). 

Create a new file with this code:

<script>
document.write("Hey my name is Lisa"); 
</script>

Save the file as hello.html
In Sublime it should look like this:



Open the file in a browser like Chrome. 


Great! If you didn’t get this to work, ask a teacher!


The text “Hey my name is Lisa” is called a string

We can create new strings by combing other strings. We combine strings using the plus sign (+).

Now we will combine three strings: