Some tips on date operations in kotlin....differen...
# getting-started
d
Some tips on date operations in kotlin....difference between dates adding a number of days to a particular date
google 1
d
Use Java 8's date / time libraries. They are awesome
The two problems you mentioned:
val dur = Duration.between(date1, date2)
val later = myTime.add(3, DAYS)
etc.
It's well documented and there are many examples
📖 2
👓 2
d
Thanks......i imported java.time* but add api not available