Google Interview Question

Currency conversion graph theory problem