How to get time differences in decimal format?