You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
Clement Denis 711dabdb12 create editor version of init/hello-there for the origin piscine 2 years ago
..
README.md create editor version of init/hello-there for the origin piscine 2 years ago

README.md

Hello There 👋

Values

There are 3 types of values, and they can model the WORLD !
(In the end it's all 1's and 0's for the computer), but us, humans, need an easier way of representing stuff.

We can all agree that 11010001100101110110011011001101111 is not a very friendly way to say 'hello' !

Numbers 🔢

  • Whole numbers: 1, 23, 232139283
  • Negative numbers are prefixed with -: -1, -1231
  • Decimal numbers: 3.14, -2.53343 etc...

Use them for quantities like in daily life.

Booleans /

We use them when something is either true or false.

They can be used to represent an answer to a closed-ended question (anything that can be answered with yes or no).

We would answer the question Is your screen turned on ? with the value true (most likely).

Strings 🆒

  • 'Hello'
  • 'This is some text'

A string is a sequence of characters used to represent text, it needs delimiters to define its begining and end.
Delimiters are matching quotes, either `, " or '.

Using console.log

To display output from a script into a console, use the function console.log:

console.log() // <- will show an empty line

Add any value between the parentheses to see it appear when the script is executed.

It is very important to use this often to validate that our code is valid. The more it is tested, the easier it is to understand what's going on in the code !

In doubt, console.log everything, don't be shy, they are for free.

Instructions

In the editor block, write a program that displays:

  • the exact text Hello There !
  • any Number
  • and a Boolean.

Recommendation

Videos designed to give hints are assigned to each quest. It is strongly suggested to watch them as you go.

You will learn about

  • JavaScript primitive values