单项选择题

Luckily,the poor boy had enough money ()he could buy a train ticket.

A.by which
B.on which
C.with which
D.for which