This repository houses several projects developed during Kotlin Core
course provided by JetBrains Academy
The projects are developed using Kotlin 2.0
and several additional packages:
- kotlin-reflect for some metadata manipulation
- arrow in combination with context parameters
- kotlinpoet to generate test case data in indigo-card-game
- junit-jupiter and assertk for unit testing
All these projects are essentially console applications which communicate with the user in a request-response manner
List is ordered by project completion date
A simple app which parsers and converts different types of unit (length, weight and temperature). The core conversion logic is located in Unit.kt
An arithmetic calculator which supports main operators [+, -, *, /, ^]
, calculations in parentheses and variable assignment.
Calculation is based on the Polish Postfix Notation and implemented in Calculator.kt
Expression tokenization and parsing is located in package calculator.parser
A text-only card game with several neat features:
- [2-8] players supported;
- Two kinds of Player:
User
andComputer
; - Each game can be played by any number of users/computers (as long as the total number of players is correct);
- Fully immutable state with event-based logic: GameEvent.kt
CLI tool which provides several commands to observe git repository content:
cat-file
- display git object's (commit, tree or blob) content with the specified hashlist-branches
- list all repository branches and specify which is the current onelog
- show a full commit history for a specified branchcommit-tree
- show a full git file system tree of a commit with the specified hash
This one is my favorite because it required a lot of reverse engineering, and it helped me to get a better understanding of git internal structure
📠 contacts
A phone book application with several contact types supported.
Implementation is heavily based on Arrow
library - Either<E, R>
, Ior<E, R>
, Raise<Error>
types and opted-in Kotlin context parameters.
Also in this project I used Either
-returning constructor technique (like here),
which I learned about from a great book by Alejandro Serrano Mena: FP Ideas for the Curious Kotliner