loading...

Discussion on: Daily Challenge #30 - What is the price?

Collapse
kvharish profile image
K.V.Harish

My solution in js

const discoverOriginalPrice = (salePrice, discount) => isFinite(a = (salePrice / ((100 - discount) / 100)).toFixed(2)) ? a : 0;

Handles 100% discount 😉