---
# System prepended metadata

title: 13567 - Hot pot time
tags: [math]

---

# 13567 - Hot pot time
>author: Utin
###### tags: `math`

---

## Brief
See the code below

## Solution 0

```c=
#include <stdio.h>

int main(void) {
	int a1, a2, a3, a4, a5, a6;
	int b1, b2, b3, b4, b5, b6;
	int sum = 0;
	scanf("%d/%d/%d %d:%d:%d", &a1, &a2, &a3, &a4, &a5, &a6);
	scanf("%d/%d/%d %d:%d:%d", &b1, &b2, &b3, &b4, &b5, &b6);
	if (a3 != b3) {
		sum = 0;
		sum += b4 * 3600 + b5 * 60 + b6;
		sum += 86400 - (a4 * 3600 + a5 * 60 + a6);
	}
	else {
		sum = 0;
		sum += (b4 - a4) * 3600 + (b5 - a5) * 60 + b6 - a6;
	}
	printf("%d\n", sum);
}
// By Utin
```

## Reference