Skip to content

Latest commit

 

History

History
40 lines (33 loc) · 1.21 KB

README.md

File metadata and controls

40 lines (33 loc) · 1.21 KB

How to run (example)

python buyer.py ETH 16

Programming Test

  • Background

  • Task

  • Inputs

    • currency name (like "ETH")
    • amount to sell (like 16)
  • Outputs

    • The function returns how much bitcoin you would get for selling that amount, by looking at the current buy offers
    • buy offers look like this (click below to expand) "buy" : [ { "Quantity" : 12.00000000, "Rate" : 0.02525000 }, { "Quantity" : 15.37000000, "Rate" : 0.02515000 }, { "Quantity" : 11.37000000, "Rate" : 0.02505000 }, ],
    • Selling 16 units into this orderbook would sell 12 at 0.02525000 and 4 at 0.02515000
    • result would be 0.4036