Let's assume the speed of the current is "c" km/hour.
When the boat is going with the current, its effective speed will be the sum of the boat's speed in still water and the speed of the current. So, the effective speed is (12 + c) km/hour.
When the boat is going against the current, its effective speed will be the difference between the boat's speed in still water and the speed of the current. So, the effective speed is (12 - c) km/hour.
Let's say the distance traveled is "d" km. We are given that the boat takes twice as much time to cover this distance against the current compared to going with the current.
The time taken to travel the distance with the current is given by: Time = Distance / Speed = d / (12 + c)
The time taken to travel the same distance against the current is given by: Time = Distance / Speed = d / (12 - c)
According to the given information, the time taken against the current is twice the time taken with the current:
d / (12 - c) = 2 * (d / (12 + c))
Now, we can solve this equation to find the value of "c":
(12 + c) / (12 - c) = 2
Cross-multiplying:
12 + c = 2 * (12 - c)
12 + c = 24 - 2c
3c = 12
c = 12 / 3
c = 4
Therefore, the speed of the current is 4 km/hour.