Skip to content

This repository contains the solution to the "Classificador de nível de Herói" challenge proposed by DIO.me. The goal of the challenge is to implement a program that takes a hero's name and amount of experience (XP) and determines the hero's level.

License

Notifications You must be signed in to change notification settings

annielymariah/hero-level-classifier-DIO

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

⚔️ Hero Level Classifier 🎮

Description

This project is a solution to the "Classificador de nível de Herói" challenge proposed by the DIO.me course. The goal of this challenge is to implement a system that classifies a hero's level based on their experience (XP), using fundamental programming concepts such as variables, operators, loops, and decision structures.

Challenge Requirements

The application must:

  1. Request the hero's name and their experience points (XP).
  2. Classify the hero's level according to the following table:
    • XP < 1,000 → Iron
    • 1,001 ≤ XP ≤ 2,000 → Bronze
    • 2,001 ≤ XP ≤ 5,000 → Silver
    • 5,001 ≤ XP ≤ 7,000 → Gold
    • 7,001 ≤ XP ≤ 8,000 → Platinum
    • 8,001 ≤ XP ≤ 9,000 → Ascendant
    • 9,001 ≤ XP ≤ 10,000 → Immortal
    • XP ≥ 10,001 → Radiant
  3. Display a message with the hero's level in the following format:
    The Hero named {name} is at the level of {level}.  
    

Tools and Concepts Used

  • Variables
  • Operators
  • Loops
  • Decision Structures

How to Run the Project

  1. Install Node.js
    First, you need to have Node.js installed on your computer. If you haven't done so yet, download and install it from the official website:

  2. Clone this repository:

    git clone https://github.com/annielymariah/hero-level-classifier-DIO.git  
  3. Navigate to the project directory:

    cd hero-level-classifier-DIO
  4. Install the dependencies:
    Before running the script, you need to install the required dependencies. Run the following command:

    npm install  
  5. Run the script:
    After installing the dependencies, execute the project with:

    npm start  
  6. Follow the on-screen prompts to input the hero's name and experience points (XP).

About

This repository contains the solution to the "Classificador de nível de Herói" challenge proposed by DIO.me. The goal of the challenge is to implement a program that takes a hero's name and amount of experience (XP) and determines the hero's level.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published