Created
January 13, 2020 19:13
-
-
Save yongjhih/a0a17adaef0eb5fc7dbba5e6924ed8de to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extension ComparableRangeX<T> on Comparable<T> { | |
bool between(T min, T max) => compareTo(min) >= 0 && compareTo(max) <= 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment