</>OfferRetriever
DashboardDiscuss
NEW

Spring Hire Sale

Limited Time Deal: Unlock all premium questions for over 30% off

$10.42$7.08

08

:

04

:

48

:

09

Get this deal
Back to Dashboard

Exchange Rate Finder

Medium

You are given a set of currency exchange relationships. Each relationship specifies a direct exchange rate between two currencies. Rates are bidirectional: if the rate from currency A to currency B is r, then the rate from B to A is 1/r. The best exchange rate between two currencies is the maximum value achievable by multiplying the rates along any valid path through the currency network.

Implement the CurrencyConverter class: ...