Basics of HTML, CSS & JS

HTML & CSS Book

Chapter 2 “Text” ::

Chapter 10: “Introducing CSS”

P {color:black ; fonr-size-20px}

selectors types

 




 

JavaScript Book

Chapter 2 “Basic JavaScript Instructions” ::

JavaScript is case sensitive this mean Sohaib not equal SOHAIB or sohaib

6 Rules to choose the variable name :

  1. The name must begin with a letter, dollar sign ($),or an underscore (_). It must not start with a number.
  2. The name can contain letters, numbers, dollar sign ($), or an underscore (_). Note that you must not use a dash(-) or a period (.) in a variable name.
  3. You cannot use keywords or reserved words. Keywords are special words that tell the interpreter to do something. For example, var is a keyword used to declare a variable. Reserved words are ones that may be used in a future version of JavaScript. ONLINE EXTRA View a full list of keywords and reserved words in JavaScript.
  4. All variables are case sensitive so score and Score would be different variable names, but it is bad practice to create two variables that have the same name using different cases.
  5. Use a name that describes the kind of information that the variable stores. For example, fi rstName might be used to store a person’s first name, l astNarne for their last name, and age for their age.
  6. If your variable name is made up of more than one word, use a capital letter for the first letter of every word after the first word. For example, f i rstName rather than fi rstnarne (this is referred to as camel case). You can also use an underscore between each word (you cannot use a dash).

Expressions :

Operators :

 


 

Chapter 4 “DECISIONS & LOOPS” ::

[1] Comparison operators:

[2] Logical operators :


 

GitHub Profile