Introduction In many cases, we might be interested in checking dates to see if they fit in the range or numbers to see if they fall between the given range of numbers. Kotlin has a short hand way to represent the range which can be quite handy fun checkInRange(date: MyDate, first: MyDate, last: MyDate): Boolean { return date in first..last } The above snippet of code is used to check the date (1st argument) lies between the first and the last date ranges.
I have 11+ years of experience in Software development. I am proud to be in the top 5 Multi-Tenancy answerers @ Stackoverflow. I have worked with C#, Java, MySQL, SQL Server, Multi-tenancy, AWS, Azure, Terraforms, Java with Spring boot and Python, groovy, bat scripts