lokytech5 / Java-FizzBuzz

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

FizzBuzz Java Application

This is a simple Java console application that determines if a given number is "Fizz", "Buzz", "FizzBuzz", or none of the above.

How to Run

  1. Make sure you have Java installed on your machine.
  2. Clone or download this repository.
  3. Open a terminal or command prompt.
  4. Navigate to the directory containing the downloaded files.
  5. Compile the Java source code.
  6. Run the application using the command: ctrl + R on intellij IDEA for mac ox. for windows Press Ctrl + Shift + F10 (or go to Run > Run 'FizzBuzzApp.main()'). This will compile and run the application.
  7. Follow the on-screen instructions to enter a number and see if it's "Fizz", "Buzz", "FizzBuzz", or none.

Usage

  1. The program will prompt you to enter a number.
  2. It will then determine if the number is divisible by 3, 5, both, or neither.
  3. Depending on the divisibility, the program will display corresponding messages:
  • "Fizz" for numbers divisible by 3.
  • "Buzz" for numbers divisible by 5.
  • "FizzBuzz" for numbers divisible by both 3 and 5.
  • A message indicating that the number is neither "Fizz" nor "Buzz" if none of the above conditions are met.

Contributing

Contributions are not typically expected for this simple example. However, if you'd like to enhance or modify the application, feel free to fork the repository and create a pull request.

License

This project is licensed under the MIT License.

About


Languages

Language:Java 100.0%