Added idea how to solve problem when time difference is greater one second
moved to proper place