Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- function getName(){
- return "Harry Potter";
- }
- function getEnemy(){
- return "Dragon";
- }
- function getLocation(){
- return "Darkwood Forest";
- }
- function sentence(){
- echo "Deep in " . getLocation() . ", " . getName() . " battled a great " . getEnemy() . ".";
- //Would echo "Deep in Darkwood Forest, Harry Potter battled a great Dragon."
- }
- sentence();
- ?>
Add Comment
Please, Sign In to add comment