<<<<<<< HEAD
we can evaluated a situation by comparing one value in the script to what you expect it might be, and the result will be a boolean(true or false). 1. equal to(==): this operator compares two values to see if they are the same. the valuescould be bool,string,numbers. 2. not equal to(!=):this operator compares two values to see if they are not the same. 3. strict equal to(===): this operator compares two values to check the data type and the value same. 4. strict not equal to(!==): this operator compares two values to check the data type and the value are not same. 5. greater than (>): this operator check if the number on the left is greater than the number on the right. 6. less than (<): this operator check if the number on the left is less than the number on the right. 7. greater than or equal to (>=): this operator check if the number on the left is greater than or equal the number on the right 8. less than or equal (<):this operator check if the number on the left is less than or equal the number on the right.
that allow you to compare the result of more thanon Comparison operator by usin (and ,or) operators (&&,||,!). * logical And(&&): this operator test more there one condition. * logical Or(||): this operator test at least one condition. * logical Not(!):this operator takes a single boolean value and inverts it.
loops check the condition, if it returns true a code block will run.then the condition will be checked again and if it still returns true the code block will run again.it will repeat until the condition return false.There are 3 common types of loop : 1. FOR LOOP :to run a specific number of time and the condition is usually a counter which is used to tell how many time the should do run. 2. WHILE LOOP : if you dont know how many times the code should run; the condition can be something other than counter and the code will countinue to loop for as long as the condition is true. 3. DO WHILE LOOP:its similler to WHILE loop but has one key difference it will always run the statements inside the curly braces at least once even if condition evaluates to false.
for loop uses a counter as a condition; this instructs the code to run for a specific number of time.
- initialization : creat a variable and assign value to it.
- condition : the loop should countinue to run until the counter reaches a specified number.
- update : every time the loop has run the statements in the curly braces it adds one to the counter.
=======
- How Computers Work?
- What makes a computer a computer?
- How information is represented using elecricity? 4.How computer use circuits to do every things? The computer change the world, and the different parts of computers the input, output and store all the information
the computer Is available every where in the packet,cars and offices. to design machine it walk in many differenttasks;it would need to: 1. take input. 2. store information 3. processe it. 4. output the result. these are a common to all computer and tats what make a computer a computer.
there are many types of input. what is the input its a stuff the world does make a computerdo stuff, you can tell computerto do in the keyboread,what to do the mouse,camera ,mik....
all the difference input give a computer information which then store in memory. a computer processor takes informationfrom memory and then manipulated with changes algorithim its just series of command,then since the process informationback to be stored in memory again. Then ready to output.
How the computer output information depends on what computer design? a computer display shows a text,photo,videos,games,VR and when the computer connect over the internet the output from computer become input another.
the computerwork on ones and zeros but almost nobody deals directly with ones and zeros. ones and zeros; do play a big work in how computer work on the inside. inside the computerthere are an electric wires and circuitsthat carry all the information in a computer.
- How do you store or represented information using elecricity?
- single wire :it could be ON or OFF. its important to be start,its called a bit and its the smallest piece of information a computercan store.Even if we use 1 wire there are 2 bits (0.1) using 2 wires there are 8 bit ... with more bits you can represented more complex information
we only have 2 digit (0,1) with tgese 2 digits we can count uo any numbers. In Binary each position carry a value,the important is any number can be represented with ones and zeros. if we use 8 wire :we can store the number between 0 and 255. 32 wires we can store the number between 0 and 4 Billion. with Binary number also can represent the image, text,and videos.
- text in binary: we can represent any pargraph to the sequence number and thses numbers stores in ones and zeros singles.
- image in binary : photo,videos and graphics it made of many pixels and each pixels has a color (red,blue,green)and each of color represented with numbers.
- sound in binary :every sound is a series of vibration. vibration come be represented graphicaly as a wave form, any point in the waves can be represented by a numberin this way the sound can be broken down into a series of numbers.
a1b9040ff8067f66227743a081be43e426308cfd



