Lecture Notes
Tutorial 3 - Data Types and Operators
\b Backspace
\f Form feed
\n New line
\r Carriage return
\t Horizontal tab
\’ Single quotation mark
\" Double quotation mark
\\ Backslash
x = 100;
y = 200;
x += y; // x changes to 300
x = 3;
y = 2;
x %= y; // x changes to 1 (remainder of 3/2)
|| Or operator
operand1 operand2 result
false false false
false true true
true false true
true true true
! Not operator
operand result
false true
true false