A set of short, beginner-friendly Java and Kotlin exercises for high school robotics students. Each exercise is a separate Gradle subproject with its own README, starter code, and JUnit tests so one broken module will not block the rest.
- Install JDK 17+ and Gradle (or use the included Gradle wrapper scripts once generated).
- From the repo root, run
./gradlew :java:module-name:testfor the Java track or./gradlew :kotlin:module-name:testfor the Kotlin track. - Each module README explains goals, starter files, and what to implement. Tests will fail until you complete the exercise.
- Timebox each module to 15–30 minutes.
- Java exercises live in
java/<module>. - Kotlin mirrors live in
kotlin/<module>and point to the Java README for full instructions, but code lives undersrc/main/kotlinandsrc/test/kotlin.
01-setup-hello-world02-variables-and-types03-expressions-and-control-flow04-loops-and-iteration05-methods-and-parameters06-arrays-and-lists07-classes-and-objects08-encapsulation-and-immutability09-enums-and-switch10-error-handling11-basic-io12-unit-testing-basics13-test-driven-exercise14-collections-and-maps15-inheritance-and-interfaces16-functional-basics17-capstone-mini-robot-command
Work through them in order or pick topics you want to practice. Good luck and have fun! 🚀