Created
November 13, 2020 14:07
-
-
Save miensol/4fde0ac4aa0fab679687fb651c3c8cf2 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
import org.joda.time.DateTime | |
import org.joda.time.Minutes | |
val now = DateTime.now() | |
val past = now.minusMinutes(3) | |
println(Minutes.minutesBetween(past, now).minutes) | |
println(Minutes.minutesBetween(now, past).minutes) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment