---
id: 5d7df75a8360d21c6826a9b4
title: Part 99
challengeType: 0
isBeta: true
---
## Description
At the end of that line, add a random number between one and the value of `xp`. Here is the formula to get a random number between 1 and 5: `Math.floor(Math.random() * 5) + 1`.
`Math.random()` returns a decimal or floating point number between 0 and 1, and `Math.floor()` rounds a given number down to the nearest integer.
## Instructions
## Tests
```yml
tests:
- text: See description above for instructions.
testString: xp = 1, fightDragon(), monsterHealth = 20, attack(), assert(monsterHealth === 14);
```
## Challenge Seed
```html
```
### Before Test
```html
RPG - Dragon Repeller
XP: 0Health: 100Gold: 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.