# Order matters twice

Mr. Accurado, a keen and sharp eyed professional thought of starting his special assignment at few seconds past midnight.

However due to a distraction- which lasted for less than a minute - he could not start it on time but started at a time, which is exactly twice the actual time he thought of starting originally.

Also, he observed that the digits in the seconds (in hh:mm:ss format) place got swapped and there is no change in the hours digits.

Can you identify the duration of distraction/ the original time that Mr. Accurado thought of starting his assignment?

Edit: Sorry, I misinterpreted the question originally.

He probably wanted to start at

00:00:42

00:01:24

Hence, the length of the distraction was

$42$ seconds (indeed less than a minute)

Explanation

The actual start time was double the amount of time after midnight and the digits in the seconds place have swapped.

I realized this has been solved since the time I solved it, but I had to go to lunch and I created a stack exchange account just to answer this, so...

00:00:42 (42 seconds after midnight)

so his distraction was:

42 seconds long

Explanation:

42 seconds after 00:00:42 is 00:01:24, or 84 seconds.

This is how I solved it:

A and B are digits, while a and b are variables - hopefully this is proper notation.

The distraction started at some time 00:00:AB, and ended at 00:01:BA, where A and B are digits, since the amount of time between beginning and end had to be less than one minute. Since 1:BA was twice 0:AB, digit A has to be even. The beginning and end times can be re-written as 2*AB = BA + 60.

A is even -> {0, 2, 4, 6, 8}
A is first digit in number of seconds -> {0, 2, 4}
2*a*10 >= 60 -> A >= 3 -> A=4

Solving this equation: 2*(40+b) = (b*10+4)+60 gives b=2.

As hexomino already noticed, the distraction time is

42 seconds, so he started at 00:00:42 and finished at 00:01:24

In order to find this solution we can do the following:

First we notice that from the fact that the actual starting time is twice the intended starting time, it follows that the distraction time equals the intended starting time. Because the distraction time is less than a minute, it furthermore follows that this time has at most 2 digits.
Now let $s_1$ be the first digit of the starting time (or 0 if it has only 1 digit), and let $s_2$ be the second digit. The starting time now is $10s_1 + s_2$

First I will handle the case that the distraction time is less than half a minute, this namely means that the real starting time is less than a minute. This starting time therefore has to be of the form $00:00:s_2s_1$ (since the second digits were swapped). This means that $10s_2 + s_1 = 2(10s_1 + s_2)$, so $19s_1 = 8s_2$. From this it would follow that $s_2$ has to be divisible by 19 (since 19 is prime and does not divide 8), however, $s_2$ can be at most $9$, so this is only possible if $s_2 = 0$. This would mean that also $s_1 = 0$, so the intended starting time would be $00:00:00$, which is not possible since it should be a few seconds after midnight.

Now we consider the case that the distraction time is at least 30 seconds, this means that $s_1$ is between 3 and 6, and the real starting time is $00:01:s_2s_1$. We find that $60 + 10s_2 + s_1 = 2(10s_1 + s_2)$, which can be rewritten to $19s_1 = 4(15 + s_2)$. Since $19$ is coprime with $4$, it follows that $4$ divides $s_1$. Using that $s_1$ is between $3$ and $6$, we see that $s_1 = 4$. From this it again follows that $19 = 15 + s_2$, giving $s_2 = 4$. So the only valid intended starting time is indeed $00:00:42$.