Puzzle 040

Puzzle 040: Crossed Connections

This one is a fairly complex logic puzzle. There are four cables plugged into four sockets, but the cables run through lengths of pipe and can't be seen (other than two specific parts). Any horizontal pipe can only hold a single cable, but the vertical pipes can hold as any number of cables. You're match up which cable belongs to which socket.

The main hint here is that there are only 6 meters of cable per color, and each section of pipe (whether horizontal or vertical) is 1 meter long. Given that the unbroken distance between the cable start and sockets is 4 meters, that means every cable has exactly two meters worth of cable in the vertical pipes.

To further the hint, we see that Cable C starts on the third row, but ends up on the first row. That means its two vertical meters are already expended by the time it gets to that spot, so it must keep continuing horizontally. So Cable C must be in the top socket as well... so where are the others? And what does this tell us about the other exposed cable?