This repository contains a set of programming puzzles that are solved using Java or Kotlin programming language. Tests provided for every problem.
The project directory structure is as follows:
.
├── src/main # Source files
│ ├── java # Java sources
│ ├── kotlin # Kotlin sources
├── src/test # Test files
│ ├── resources/.../*tested-class-name*/ # Tested class resources (input and output files)
├── LICENSE
└── README.md
TestSource annotation and TestSourceProvider are junit's ArgumentProvider implementation that search for the test resources (input and output files) in the directory structure, the same as test(ed) class package. Allows to test different class implementations (solutions to the problem) for every input-output pair file as in the code snippet below:
@ParameterizedTest
@TestSource(
value = RucksackReorganization::class, // used as single implementation if no custom implementations provided.
implementations = [RucksackReorganization::class, IdiomaticRucksackReorganization::class]
)
fun findTotalRearrangementPriority(rucksackReorganization: RucksackReorganization, input: Path, output: Path)
With execution of 4 tests for 2 implementations and 2 input-output pairs.
Advent of Code 2022 challenge.
The following challenges from the Leetcode.
This is the list of the Top Interview Questions.
May LeetCoding consists of 31 daily problems over May. Beginner-friendly.