ZoomInfo Interview Question

Compute the total price according to a table. How to realize ParseInt?