Skip to content

Instantly share code, notes, and snippets.

View George-smart's full-sized avatar
🏠
Working from home

George Evaristus George-smart

🏠
Working from home
View GitHub Profile
// Addition Function
int addition(int num1, int num2) {
return (num1 + num2);
}
// Subtraction Function
int subtraction(int num1, int num2) {
return (num1 - num2);
}
void main(){
int odd = 1;
// looping through a number ranging from 1 - 30;
for (; odd <= 30; odd++){
// check if it is an odd number
if ((odd % 2) != 0){
// Printing the result.
print("The number is at $odd");
}