Skip to content

Conversation

sinanazifi
Copy link

1- I have made changes in the fee collecting algorithm, where the time spans were not divided correctly, also after one hour passes from the last toll passage the time pin missed an update, it fixed that.

2 - Since the data model was very simple there was no deep SOLID/ OOD approach needed. This challenge was not on the objective part of models but was more on how unrelated the data model and calculation logic was from each other. A data driven approach was the best to be applied.

3- from C# version 8 the pattern matching was introduced to help with complexities which are apart from model structure and was best to be used in such Logic layers of software for sake of making
A- logic layer very simple to read
B- test and usage of logic to become much faster and lest bulk of code is needed.

finally a unit test is created for the sake of proving the 2 public method inside calculator to be working.
and one console app is doing simple work of a calculator for a costumer whom wondering how much fee is to be paid :D

@sinanazifi sinanazifi closed this Aug 8, 2021
@sinanazifi sinanazifi reopened this Aug 8, 2021
@sinanazifi
Copy link
Author

and the movie is "Hackers" well Mrs Jolie started with that one to shine ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant