This repository contains Java practice tasks grouped by topic (operators, methods, switch, loops, exceptions).
- Small standalone Java exercises.
- One entry file
App.javafor a basic test run. - Topic folders with task files that can be run independently.
- JDK 17+ (JDK 25 LTS is also supported)
- VS Code with Java Extension Pack (recommended)
Java_Challenges/
|- src/
| |- App.java
| |- challenges_1_operators/
| |- challenges_2_methods/
| |- challenges_3_switch/
| |- challenges_5_exceptions/
| |- challenges_6_Classes/
| |- challenges_...
|- bin/ (compiled classes)
|- lib/ (external libraries, if any)
|- .vscode/
|- .gitignore
`- README.md
- Clone or download this repository.
- Open the folder in VS Code.
- Install Java extensions if prompted.
- Open any class with a
mainmethod. - Click
Runabove themainmethod.
From the project root:
Run the sample app:
javac -d bin src/App.java
java -cp bin AppRun a specific challenge file (example):
javac -d bin src/challenges_3_switch/PhoneticAlphabet.java
java -cp bin challenge.task_3_switch.PhoneticAlphabetReplace the file and class name with the task you want to run.
- Most files are independent exercises for learning and practice.
bin/stores compiled.classfiles.