Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- for ($i = 99; $i > 0; $i--) {
- switch ($i) {
- case 1:
- echo "$i bottle of beer on the wall, $i bottle of beer, take one down, pass it around, No more bottles of beer on the wall.";
- break;
- case 2:
- echo "$i bottles of beer on the wall, $i bottles of beer, take one down, pass it around, 1 more bottle of beer on the wall.";
- break;
- default:
- echo "$i bottles of beer on the wall, $i bottles of beer, take one down, pass it around, " . ($i - 1) . " bottles of beer on the wall.";
- break;
- }
- }
- ?>
Add Comment
Please, Sign In to add comment