Skip to content

Instantly share code, notes, and snippets.

@justadityaraj
Last active August 6, 2019 15:03
Show Gist options
  • Save justadityaraj/250cdba57336c4089c1f3232f0d3b7de to your computer and use it in GitHub Desktop.
Save justadityaraj/250cdba57336c4089c1f3232f0d3b7de to your computer and use it in GitHub Desktop.
<?php
//table of nine <9> with explanation
$table=9; //starting int value
$num=1; //num
while ($table<=90){ //until num
echo "9 × ".$num." is equal to ".$table."." . "\n"; //output format
$table+=9; //value to be addded in each interval
$num++; //num value add for chronological order
}
@justadityaraj
Copy link
Author

Output:

9 × 1 is equal to 9.
9 × 2 is equal to 18.
9 × 3 is equal to 27.
9 × 4 is equal to 36.
9 × 5 is equal to 45.
9 × 6 is equal to 54.
9 × 7 is equal to 63.
9 × 8 is equal to 72.
9 × 9 is equal to 81.
9 × 10 is equal to 90.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment