Quality Assurance Projects - Metric-Imperial Converter

Tell us what’s happening:
Evrything working fine but the below test won’t pass:
(You can use fractions, decimals or both in the parameter (ie. 5, 1/2, 2.5/6), but if nothing is provided it will default to 1.)
and
( Failed:Your return will consist of the initNum, initUnit, returnNum, returnUnit, and string spelling out units in the format '{initNum} {initUnitString} converts to {returnNum} {returnUnitString}' with the result rounded to 5 decimals.)

Your project link(s)

solution: boilerplate-project-metricimpconverter - Replit

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Safari/537.36

Challenge: Quality Assurance Projects - Metric-Imperial Converter

Link to the challenge:

If you submit mi in the input, your app returns:

{"initNum":1,"initUnit":"mi","returnNum":"1.60934","returnUnit":"km","string":"1 miles converts to 1.60934 kilometers"}

instead of:

{"initNum":1,"initUnit":"mi","returnNum":1.60934,"returnUnit":"km","string":"1 miles converts to 1.60934 kilometers"}

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.