IFS code example

Example 1: if statement

if( ID = josh ):
	print("ID confirmed")
    // python
else:
	print("ID does not exist")

Example 2: javascript if else

var age=20;
if (age < 18) {
	console.log("underage");
} else {
	console.log("let em in!");
}

Example 3: if statement

if( name = 'george washington'):
	print("You have the same name as the first president of the United States")
    // python 
else:
	print("You do not have the same name as George Washington")

Example 4: javascript if elseif

if (condition) {

} else if (other_condition) {

} else {

}

Tags:

Misc Example