Formula to calculate time difference from dd:mm:yy hh:min:sec

Start Time: 2010-09-20 12:37:59,820
End Time: 2010-09-20 12:38:00,804

The above time is in year-mon-day hh:min:sec, milliseconds

I have all those in individual variables

$1 represents 2010 $2 represents 09 $3 represent 20 and so on and so forth until $7

What is the formula to calculate the time difference?
Who is Participating?
srikanthradAuthor Commented:
That is a 24 hour clock, by the way.
Daniel JungesCommented:
would you like to calculate the diff in Excell or in an programming language ?
srikanthradAuthor Commented:
I need a Math Formula so I can calculate the diff in shell script.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.