reading-notes

View project on GitHub

#Read: 04a - Programming with JavaScript

Page 1-24 Intro:

  • JavaScript makes web pages more interactive by enable you 1-accessing content (like selecting element), 2- modify content, 3- REACT TO EVENTS like selecting a button, and specify a rule the browser can follow.

CH1:

  • Script includes instruction a computer can follow to achieve a goal.
  • to write a script, you need to:
    1. define your goal and list what task you want to achieve; because script is performed in order to solve a problem.
    2. Design your script tasks; like sketching every step in flow-Chart. (try to think like a computer)
    3. Code this script step by step.

Expressions + Operators: 74 - 79:

  • Expressions have two types:
    1. expressions that assign a value to a variable; Like name = ‘Noor’.
    2. expressions that use 2 or more variables in order to return a value; A= 2+3.

Operations:

  1. Assignment operators -> name = ‘Noor’
  2. Arithmetic Operators -> uses operators like + - / *%; A= 2+3 -> A= 5.
  3. Comparison operators -> Compare two or more Values, then return True/False; A= 7>2 -> A= True.
  4. Logical operators -> connect two or more expressions, then return True/False.
  5. String operators -> Combine Two or more strings; Major = ‘Web’ + ‘ Developer’ -> Major =’Web Developer’.