--- id: 5d6f6f747c812010bf3327ce title: Part 55 challengeType: 0 dashedName: part-55 --- # --description-- Now when a player tries to buy health it will only work if they have enough money. If the player does not have enough money, nothing will happen. Add an `else` statement where you can put code to run if a player dees not have enough money. Here is an example of an empty `else` statement: ```js if (num >= 5) { console.log("Num is greater than or equal to five!"); } else { } ``` # --hints-- See description above for instructions. ```js assert(buyHealth.toString().match(/\}\s*else\s*\{\s*\}/)); ``` # --seed-- ## --before-user-code-- ```html RPG - Dragon Repeller
XP: 0 Health: 100 Gold: 50
Monster Name: Health:
Welcome to Dragon Repeller. You must defeat the dragon that is preventing people from leaving the town. You are in the town square. Where do you want to go? Use the buttons above.
``` ## --after-user-code-- ```html ``` ## --seed-contents-- ```html ``` # --solutions-- ```html ```