To complete this short coding exercise, pick your preferred language and get all 9 unit tests to pass. You will need to implement a function that takes in two date ranges and returns the overlap of those date ranges as a new date range. If there is no overlap, an exception should be thrown. Make no assumptions about the order of the date ranges that are passed into the function. Please look at the tests to validate that you are returning the expected result in each case.
The following languages may one day get support:
- Rust
- Scala
- Kotlin
- Clojure
- Swift
- F#
No plans exist to develop tests for these at the moment.
brew update
brew tap caskroom/cask
brew cask install dotnet
Install the dotnet sdk from https://dotnet.microsoft.com/download
Open Visual Studio Code and follow the prompts to add extensions for C#.
Run or debug tests in VSCode. Or run them at the command-line with dotnet test
.