Let's Do it
if(condition){
// statement(s) will execute if the first condition is true
}
else if(another condition){
// statement(s) will execute if the second condition is true
}
Graduation Day
Variables: are used to store information to be referenced in a computer program.
is short for Integer and used to store nubmers like 1, 2, 3, 4, ...
is short for Character and used to store single character between single qoute like 'a', 'A', ...
is short for Character and used to store single character between single qoute like 'a', 'A', ...
if(Condition){
// statement(s) will execute if the condition's result is true
}
if(condition){
// statement(s) will execute if the condition is true
}
else{
// statement(s) will execute if the condition is false
}
Flow control is the management of data flow between computers or devices so that the data can be handled at an efficient pace.
we can begin to operate with them by using operators. What follows is a complete list of operators.
x = 5;
Here we assigned x with the value 5, so "=" is assign operator and "==" is the equal operator
x = x++;
Here we are incrementing the variable x by 1.
To increment the variable x with any number you can use x+=5; (for example)
x = x--;
Here we are dncrementing the variable x by 1.
To dncrement the variable x with any number you can use x-=5; (for example)
The normal operations that we use every day
+ addition
- subtraction
* multiplication
/ division
% modulo