W4 6831 then FR 5323 at Madrid
Torino → Madrid → Milan Bergamo
Timetable, Madrid time
12:25W4 6831 from Torino at the gate
11:05FR 5323 to Milan Bergamo leaves the gate
22 h 40 apart on the timetable, overnight
FR 5323 leaves 22 h 40 after W4 6831 arrives on the timetable: more than half a day, so not a connection we count.