{"id":704,"date":"2021-04-21T05:57:46","date_gmt":"2021-04-21T05:57:46","guid":{"rendered":"https:\/\/bcisnotes.com\/fourthsemester\/?p=704"},"modified":"2021-04-21T05:57:46","modified_gmt":"2021-04-21T05:57:46","slug":"javascript-operators-client-side-scripting-bcis-notes","status":"publish","type":"post","link":"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/","title":{"rendered":"JavaScript Operators || Client Side Scripting || BCIS Notes"},"content":{"rendered":"<div class=\"page\" title=\"Page 15\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<h1 style=\"text-align: center;\">JavaScript Operators<\/h1>\n<\/div>\n<\/div>\n<div class=\"section\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Operators are symbols or keywords that tell the JavaScript engine to perform some sort of actions. For example, the addition (+) symbol is an operator that tells the JavaScript engine to add two variables or values, while the equal-to (==), greater-than (&gt;), or less-than (&lt;) symbols are the operators that tell the JavaScript engine to compare two variables or values.<\/p>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<h3>Arithmetic Operator<\/h3>\n<table width=\"921\">\n<tbody>\n<tr>\n<td><b>Operator<\/b><\/td>\n<td><b>Description<\/b><\/td>\n<td><b>Example<\/b><\/td>\n<td><b>Result<\/b><\/td>\n<\/tr>\n<tr>\n<td>+<\/td>\n<td>Addition<\/td>\n<td>$a + $b<\/td>\n<td>Sum of $a and $b<\/td>\n<\/tr>\n<tr>\n<td>&#8211;<\/td>\n<td>Subtraction<\/td>\n<td>$a &#8211; $b<\/td>\n<td>Difference of $a and $b<\/td>\n<\/tr>\n<tr>\n<td>*<\/td>\n<td>Multiplication<\/td>\n<td>$a * $b<\/td>\n<td>Product of $a and $b<\/td>\n<\/tr>\n<tr>\n<td>\/<\/td>\n<td>Division<\/td>\n<td>$a \/ $b<\/td>\n<td>Quotient of $a and $b<\/td>\n<\/tr>\n<tr>\n<td>%<\/td>\n<td>Modulus<\/td>\n<td>$a % $b<\/td>\n<td>Remainder of $a divided by $b, and so on.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>var x = 10;<\/p>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"page\" title=\"Page 16\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>var y = 5;<br \/>\nalert(x + y); \/\/ 0utputs: 15<\/p>\n<p>alert(x &#8211; y); \/\/ 0utputs: 5<\/p>\n<p>alert(x * y); \/\/ 0utputs: 50<\/p>\n<p>alert(x \/ y); \/\/ 0utputs: 2<\/p>\n<p>alert(x % y); \/\/ 0utputs: 2<\/p>\n<h3>JavaScript Assignment Operators<\/h3>\n<p>The assignment operators are used to assign values to variables.<\/p>\n<\/div>\n<\/div>\n<div class=\"layoutArea\">\n<div class=\"column\"><\/div>\n<div class=\"column\">\n<table width=\"921\">\n<tbody>\n<tr>\n<td><b>Operator<\/b><\/td>\n<td><b>Description<\/b><\/td>\n<td><b>Example<\/b><\/td>\n<td>\n<div class=\"page\" title=\"Page 16\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p><strong>Is The Same As<\/strong><\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>=<\/td>\n<td>\n<div class=\"page\" title=\"Page 16\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Assign<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/td>\n<td>$a = $b<\/td>\n<td>$a = $b<\/td>\n<\/tr>\n<tr>\n<td>+=<\/td>\n<td>\n<div class=\"page\" title=\"Page 16\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Add and assign<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/td>\n<td>$a += $b<\/td>\n<td>$a= $a + $b<\/td>\n<\/tr>\n<tr>\n<td>-=<\/td>\n<td>\n<div class=\"page\" title=\"Page 16\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Subtract and assign<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/td>\n<td>$a -= $b<\/td>\n<td>$a= $a &#8211; $b<\/td>\n<\/tr>\n<tr>\n<td>*=<\/td>\n<td>\n<div class=\"page\" title=\"Page 16\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Multiply and assign<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/td>\n<td>$a *= $b<\/td>\n<td>$a= $a * $b<\/td>\n<\/tr>\n<tr>\n<td>\/=<\/td>\n<td>\n<div class=\"page\" title=\"Page 16\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Divide and assign quotient<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/td>\n<td>$a \/= $b<\/td>\n<td>$a= $a \/ $b<\/td>\n<\/tr>\n<tr>\n<td>%=<\/td>\n<td>\n<div class=\"page\" title=\"Page 16\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Divide and assign modulus<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/td>\n<td>$a %= $b<\/td>\n<td>$a= $a % $b<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>var a; \/\/ Declaring Variable<br \/>\na = 20;<br \/>\nalert(a); \/\/ Outputs: 20<\/p>\n<p>a = 20;<br \/>\na += 30;<br \/>\nalert(a); \/\/ Outputs: 50<\/p>\n<p>a = 40;<\/p>\n<p>a -= 20;<\/p>\n<\/div>\n<\/div>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<div class=\"page\" title=\"Page 17\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>alert(a); \/\/ Outputs: 20<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"page\" title=\"Page 17\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>a = 5;<br \/>\na *= 15;<br \/>\nalert(a); \/\/ Outputs: 75<\/p>\n<p>a = 40;<br \/>\na \/= 10;<br \/>\nalert(a); \/\/ Outputs: 4<\/p>\n<p>a = 100;<br \/>\na %= 15;<br \/>\nalert(a); \/\/ Outputs: 10<\/p>\n<h3>JavaScript String Operators<\/h3>\n<p>There are two operators which can also be used be for strings.<\/p>\n<table width=\"921\">\n<tbody>\n<tr>\n<td><b>Operator<\/b><\/td>\n<td><b>Description<\/b><\/td>\n<td><b>Example<\/b><\/td>\n<td><b>Result<\/b><\/td>\n<\/tr>\n<tr>\n<td>+<\/td>\n<td>\n<div class=\"page\" title=\"Page 17\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Concatenation<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"page\" title=\"Page 17\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>str1 + str2<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"page\" title=\"Page 17\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Concatenation of str1 and str2<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"page\" title=\"Page 17\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>+=<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"page\" title=\"Page 17\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Concatenation assignment<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"page\" title=\"Page 17\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>str1 += str2<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"page\" title=\"Page 17\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Appends the str2 to the str1<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>Example<\/p>\n<p>var str1 = &#8220;Hello&#8221;;<br \/>\nvar str2 = &#8221; World!&#8221;;<\/p>\n<p>alert(str1 + str2); \/\/ Outputs: Hello World!<\/p>\n<p>str1 += str2;<br \/>\nalert(str1); \/\/ Outputs: Hello World!<\/p>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"page\" title=\"Page 18\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<h3>JavaScript Incrementing and Decrementing<\/h3>\n<p>The increment\/decrement operators are used to increment\/decrement a variable&#8217;s value.<\/p>\n<\/div>\n<\/div>\n<table width=\"916\">\n<colgroup>\n<col \/>\n<col \/>\n<col \/><\/colgroup>\n<tbody>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p><strong>Operator<\/strong><\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p><strong>Name<\/strong><\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p><strong>Effect<\/strong><\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>++a<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Pre-increment<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Increments a by one, then returns a<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>a++<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Post-increment<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Returns a, then increments a by one<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>&#8211;a<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Pre-decrement<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Decrements a by one, then returns a<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>a&#8211;<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Post-decrement<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Returns a, then decrements a by one<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>var a; \/\/ Declaring Variable<\/p>\n<p>a = 12;<br \/>\nalert(++a); \/\/ Outputs: 13<\/p>\n<p>alert(a); \/\/ Outputs: 13<\/p>\n<p>a = 12;<br \/>\nalert(a++); \/\/ Outputs: 12<\/p>\n<p>alert(a); \/\/ Outputs: 13<\/p>\n<p>a = 12;<br \/>\nalert(&#8211;a); \/\/ Outputs: 11<\/p>\n<p>alert(a); \/\/ Outputs: 11<\/p>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"page\" title=\"Page 19\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>a = 12;<br \/>\nalert(a&#8211;); \/\/ Outputs: 12<\/p>\n<p>alert(a); \/\/ Outputs: 11<\/p>\n<h3>JavaScript Logical Operators<\/h3>\n<p>The logical operators are typically used to combine conditional statements.<\/p>\n<\/div>\n<\/div>\n<table width=\"922\">\n<colgroup>\n<col \/>\n<col \/>\n<col \/>\n<col \/><\/colgroup>\n<tbody>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p><strong>Operator<\/strong><\/p>\n<\/div>\n<\/div>\n<\/td>\n<td><img decoding=\"async\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAACsAAAAGCAYAAABab2coAAAAAXNSR0IArs4c6QAAAHhlWElmTU0AKgAAAAgABAEaAAUAAAABAAAAPgEbAAUAAAABAAAARgEoAAMAAAABAAIAAIdpAAQAAAABAAAATgAAAAAAA1CnAAALrwADUKcAAAuvAAOgAQADAAAAAQABAACgAgAEAAAAAQAAACugAwAEAAAAAQAAAAYAAAAAtHfs8AAAAAlwSFlzAAALLAAACywBrWgDXAAAABVJREFUOBFjYBgFoyEwGgKjIQAKAQAEDgABmTPHxQAAAABJRU5ErkJggg==\" alt=\"page19image32848896\" width=\"42.250000\" height=\"6.000000\" \/><\/p>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p><strong>Name<\/strong><\/p>\n<\/div>\n<\/div>\n<p><img decoding=\"async\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAACsAAAAGCAYAAABab2coAAAAAXNSR0IArs4c6QAAAHhlWElmTU0AKgAAAAgABAEaAAUAAAABAAAAPgEbAAUAAAABAAAARgEoAAMAAAABAAIAAIdpAAQAAAABAAAATgAAAAAAAABIAAAAAQAAAEgAAAABAAOgAQADAAAAAQABAACgAgAEAAAAAQAAACugAwAEAAAAAQAAAAYAAAAAZAKYegAAAAlwSFlzAAALEwAACxMBAJqcGAAAABVJREFUOBFjYBgFoyEwGgKjIQAKAQAEDgABmTPHxQAAAABJRU5ErkJggg==\" alt=\"page19image32849280\" width=\"43.000000\" height=\"6.000000\" \/><\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p><strong>Example<\/strong><\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p><strong>Result<\/strong><\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>&amp;&amp;<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>And<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>a &amp;&amp; b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>True if both a and b are true<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>||<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Or<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>a || b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>True if either a or b is true<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>!<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Not<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>!a<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>True if a is not true<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>var year = 2021;<\/p>\n<p>\/\/ Leap years are divisible by 400 or by 4 but not 100<br \/>\nif((year % 400 == 0) || ((year % 100 != 0) &amp;&amp; (year % 4 == 0))){<\/p>\n<p>alert(year + &#8221; is a leap year.&#8221;);<\/p>\n<p>} else{<\/p>\n<p>alert(year + &#8221; is not a leap year.&#8221;); }<\/p>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"page\" title=\"Page 20\">\n<div class=\"layoutArea\">\n<div class=\"column\">\n<h3>JavaScript Comparison Operators<\/h3>\n<p>The comparison operators are used to compare two values in a Boolean fashion.<\/p>\n<\/div>\n<\/div>\n<table>\n<colgroup>\n<col \/>\n<col \/>\n<col \/>\n<col \/><\/colgroup>\n<tbody>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Operator<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Name<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Example<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Result<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>==<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Equal<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>a == b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>True if a is equal to b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>===<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Identical<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>a === b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>True if a is equal to b, and they are of the same type<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>!=<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Not equal<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>a != b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>True if a is not equal to b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>!==<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Not identical<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>a !== b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>True if a is not equal to b, or they are not of the same type<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>&lt;<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Less than<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>a&lt;b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>True if a is less than b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>&gt;<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Greater than<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>a&gt;b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>True if a is greater than b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>&gt;=<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Greater than or equal to<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>xa&gt;= b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>True if a is greater than or equal to b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>&lt;=<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>Less than or equal to<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>xa&lt;= b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<td>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>True if a is less than or equal to b<\/p>\n<\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<div class=\"layoutArea\">\n<div class=\"column\">\n<p>var a = 35; var b = 45; var c = &#8220;35&#8221;;<\/p>\n<p>alert(a == c); \/\/ Outputs: true<\/p>\n<p>alert(a === c); \/\/ Outputs: false<\/p>\n<p>alert(a != b); \/\/ Outputs: true<\/p>\n<p>alert(a !== c); \/\/ Outputs: true<\/p>\n<p>alert(a &lt; c); \/\/ Outputs: true<\/p>\n<p>alert(a &gt; b); \/\/ Outputs: false<\/p>\n<p>alert(a &lt;= b); \/\/ Outputs: true<\/p>\n<p>alert(a &gt;= b); \/\/ Outputs: false<\/p>\n<p style=\"text-align: left;\">If you liked our content JavaScript Operators, then you will also\u00a0<a href=\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-data-types-client-side-scripting-bcis-notesz\/\">JavaScript Data Types\u00a0<\/a><\/p>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<div class=\"mh-excerpt\"><p>JavaScript Operators Operators are symbols or keywords that tell the JavaScript engine to perform some sort of actions. For example, the addition (+) symbol is <a class=\"mh-excerpt-more\" href=\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/\" title=\"JavaScript Operators || Client Side Scripting || BCIS Notes\">[&#8230;]<\/a><\/p>\n<\/div>","protected":false},"author":3,"featured_media":705,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[227,226,231],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v23.5 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>JavaScript Operators || Client Side Scripting || BCIS Notes<\/title>\n<meta name=\"description\" content=\"JavaScript Operators are symbols or keywords that tell the JavaScript engine to perform some sort of actions.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"JavaScript Operators || Client Side Scripting || BCIS Notes\" \/>\n<meta property=\"og:description\" content=\"JavaScript Operators are symbols or keywords that tell the JavaScript engine to perform some sort of actions.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/\" \/>\n<meta property=\"og:site_name\" content=\"BCIS Fourth Semester\" \/>\n<meta property=\"article:published_time\" content=\"2021-04-21T05:57:46+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/bcisnotes.com\/fourthsemester\/wp-content\/uploads\/2021\/04\/bcis-13.png\" \/>\n\t<meta property=\"og:image:width\" content=\"340\" \/>\n\t<meta property=\"og:image:height\" content=\"230\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Her Highness\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Her Highness\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/\"},\"author\":{\"name\":\"Her Highness\",\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/#\/schema\/person\/fcc10e27b06f3f95367e914911b47eb3\"},\"headline\":\"JavaScript Operators || Client Side Scripting || BCIS Notes\",\"datePublished\":\"2021-04-21T05:57:46+00:00\",\"dateModified\":\"2021-04-21T05:57:46+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/\"},\"wordCount\":682,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/#organization\"},\"image\":{\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/bcisnotes.com\/fourthsemester\/wp-content\/uploads\/2021\/04\/bcis-13.png\",\"keywords\":[\"Client Side Scripting\",\"JavaScript\",\"JavaScript Operators\"],\"articleSection\":[\"IT\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/\",\"url\":\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/\",\"name\":\"JavaScript Operators || Client Side Scripting || BCIS Notes\",\"isPartOf\":{\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/bcisnotes.com\/fourthsemester\/wp-content\/uploads\/2021\/04\/bcis-13.png\",\"datePublished\":\"2021-04-21T05:57:46+00:00\",\"dateModified\":\"2021-04-21T05:57:46+00:00\",\"description\":\"JavaScript Operators are symbols or keywords that tell the JavaScript engine to perform some sort of actions.\",\"breadcrumb\":{\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#primaryimage\",\"url\":\"https:\/\/bcisnotes.com\/fourthsemester\/wp-content\/uploads\/2021\/04\/bcis-13.png\",\"contentUrl\":\"https:\/\/bcisnotes.com\/fourthsemester\/wp-content\/uploads\/2021\/04\/bcis-13.png\",\"width\":340,\"height\":230,\"caption\":\"JavaScript Operators || Client Side Scripting || BCIS Notes\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/bcisnotes.com\/fourthsemester\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"JavaScript Operators || Client Side Scripting || BCIS Notes\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/#website\",\"url\":\"https:\/\/bcisnotes.com\/fourthsemester\/\",\"name\":\"BCIS Fourth Semester\",\"description\":\"Notes of Information and Technology\",\"publisher\":{\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/bcisnotes.com\/fourthsemester\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/#organization\",\"name\":\"BCIS Fourth Semester\",\"url\":\"https:\/\/bcisnotes.com\/fourthsemester\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/bcisnotes.com\/fourthsemester\/wp-content\/uploads\/2021\/02\/cropped-4-1.jpg\",\"contentUrl\":\"https:\/\/bcisnotes.com\/fourthsemester\/wp-content\/uploads\/2021\/02\/cropped-4-1.jpg\",\"width\":300,\"height\":100,\"caption\":\"BCIS Fourth Semester\"},\"image\":{\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/#\/schema\/logo\/image\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/#\/schema\/person\/fcc10e27b06f3f95367e914911b47eb3\",\"name\":\"Her Highness\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/bcisnotes.com\/fourthsemester\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/9f5c6e84ebb073447dba2985b41b0fdc?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/9f5c6e84ebb073447dba2985b41b0fdc?s=96&d=mm&r=g\",\"caption\":\"Her Highness\"},\"sameAs\":[\"http:\/\/bcisnotes.com\/fourthsemester\"],\"url\":\"https:\/\/bcisnotes.com\/fourthsemester\/author\/jaya\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"JavaScript Operators || Client Side Scripting || BCIS Notes","description":"JavaScript Operators are symbols or keywords that tell the JavaScript engine to perform some sort of actions.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/","og_locale":"en_US","og_type":"article","og_title":"JavaScript Operators || Client Side Scripting || BCIS Notes","og_description":"JavaScript Operators are symbols or keywords that tell the JavaScript engine to perform some sort of actions.","og_url":"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/","og_site_name":"BCIS Fourth Semester","article_published_time":"2021-04-21T05:57:46+00:00","og_image":[{"width":340,"height":230,"url":"https:\/\/bcisnotes.com\/fourthsemester\/wp-content\/uploads\/2021\/04\/bcis-13.png","type":"image\/png"}],"author":"Her Highness","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Her Highness","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#article","isPartOf":{"@id":"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/"},"author":{"name":"Her Highness","@id":"https:\/\/bcisnotes.com\/fourthsemester\/#\/schema\/person\/fcc10e27b06f3f95367e914911b47eb3"},"headline":"JavaScript Operators || Client Side Scripting || BCIS Notes","datePublished":"2021-04-21T05:57:46+00:00","dateModified":"2021-04-21T05:57:46+00:00","mainEntityOfPage":{"@id":"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/"},"wordCount":682,"commentCount":0,"publisher":{"@id":"https:\/\/bcisnotes.com\/fourthsemester\/#organization"},"image":{"@id":"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#primaryimage"},"thumbnailUrl":"https:\/\/bcisnotes.com\/fourthsemester\/wp-content\/uploads\/2021\/04\/bcis-13.png","keywords":["Client Side Scripting","JavaScript","JavaScript Operators"],"articleSection":["IT"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/","url":"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/","name":"JavaScript Operators || Client Side Scripting || BCIS Notes","isPartOf":{"@id":"https:\/\/bcisnotes.com\/fourthsemester\/#website"},"primaryImageOfPage":{"@id":"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#primaryimage"},"image":{"@id":"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#primaryimage"},"thumbnailUrl":"https:\/\/bcisnotes.com\/fourthsemester\/wp-content\/uploads\/2021\/04\/bcis-13.png","datePublished":"2021-04-21T05:57:46+00:00","dateModified":"2021-04-21T05:57:46+00:00","description":"JavaScript Operators are symbols or keywords that tell the JavaScript engine to perform some sort of actions.","breadcrumb":{"@id":"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#primaryimage","url":"https:\/\/bcisnotes.com\/fourthsemester\/wp-content\/uploads\/2021\/04\/bcis-13.png","contentUrl":"https:\/\/bcisnotes.com\/fourthsemester\/wp-content\/uploads\/2021\/04\/bcis-13.png","width":340,"height":230,"caption":"JavaScript Operators || Client Side Scripting || BCIS Notes"},{"@type":"BreadcrumbList","@id":"https:\/\/bcisnotes.com\/fourthsemester\/javascript-operators-client-side-scripting-bcis-notes\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/bcisnotes.com\/fourthsemester\/"},{"@type":"ListItem","position":2,"name":"JavaScript Operators || Client Side Scripting || BCIS Notes"}]},{"@type":"WebSite","@id":"https:\/\/bcisnotes.com\/fourthsemester\/#website","url":"https:\/\/bcisnotes.com\/fourthsemester\/","name":"BCIS Fourth Semester","description":"Notes of Information and Technology","publisher":{"@id":"https:\/\/bcisnotes.com\/fourthsemester\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/bcisnotes.com\/fourthsemester\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/bcisnotes.com\/fourthsemester\/#organization","name":"BCIS Fourth Semester","url":"https:\/\/bcisnotes.com\/fourthsemester\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/bcisnotes.com\/fourthsemester\/#\/schema\/logo\/image\/","url":"https:\/\/bcisnotes.com\/fourthsemester\/wp-content\/uploads\/2021\/02\/cropped-4-1.jpg","contentUrl":"https:\/\/bcisnotes.com\/fourthsemester\/wp-content\/uploads\/2021\/02\/cropped-4-1.jpg","width":300,"height":100,"caption":"BCIS Fourth Semester"},"image":{"@id":"https:\/\/bcisnotes.com\/fourthsemester\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/bcisnotes.com\/fourthsemester\/#\/schema\/person\/fcc10e27b06f3f95367e914911b47eb3","name":"Her Highness","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/bcisnotes.com\/fourthsemester\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/9f5c6e84ebb073447dba2985b41b0fdc?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/9f5c6e84ebb073447dba2985b41b0fdc?s=96&d=mm&r=g","caption":"Her Highness"},"sameAs":["http:\/\/bcisnotes.com\/fourthsemester"],"url":"https:\/\/bcisnotes.com\/fourthsemester\/author\/jaya\/"}]}},"_links":{"self":[{"href":"https:\/\/bcisnotes.com\/fourthsemester\/wp-json\/wp\/v2\/posts\/704"}],"collection":[{"href":"https:\/\/bcisnotes.com\/fourthsemester\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/bcisnotes.com\/fourthsemester\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/bcisnotes.com\/fourthsemester\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/bcisnotes.com\/fourthsemester\/wp-json\/wp\/v2\/comments?post=704"}],"version-history":[{"count":1,"href":"https:\/\/bcisnotes.com\/fourthsemester\/wp-json\/wp\/v2\/posts\/704\/revisions"}],"predecessor-version":[{"id":706,"href":"https:\/\/bcisnotes.com\/fourthsemester\/wp-json\/wp\/v2\/posts\/704\/revisions\/706"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/bcisnotes.com\/fourthsemester\/wp-json\/wp\/v2\/media\/705"}],"wp:attachment":[{"href":"https:\/\/bcisnotes.com\/fourthsemester\/wp-json\/wp\/v2\/media?parent=704"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/bcisnotes.com\/fourthsemester\/wp-json\/wp\/v2\/categories?post=704"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/bcisnotes.com\/fourthsemester\/wp-json\/wp\/v2\/tags?post=704"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}