Skip to content

Latest commit

 

History

History
42 lines (31 loc) · 1.41 KB

File metadata and controls

42 lines (31 loc) · 1.41 KB

Comparsion operators : Evaluating conditions

  • is equal to : == this operators compares two valus to see if they are the same
  • is not equal to :!= this operators compares two valus to see if they are not the same

-Type of varible :

  1. numbers
  2. string
  3. booleans
  • Greaten than :> this operate cheacks if number on left is greate than number on right.
  • less than :< this operate cheacks if number on right is greate than number on left. -- Greaten than or equal to :>= this operate cheacks if number on left is greate than or equal number on right.
  • less than or equal to :<= this operate cheacks if number on right is greate than number on left.

local operate :is usually retrun single value (ture or false).

logical operater:

  • And :&& to test more than one conditional.
  • oR:|| to test at least one conditional.
  • Not :! takes a signal boolean value and inverts it. imge

Loop counters

  • for loop : run a specified numbers of times.
  1. inteliazation : create a value and set it to zero
  2. coundition :run untial the counter resches a specified number. 3.update: addes one to the counter .

image

  • While loops:run as loong as the conditin in the parentheses is true. img