Hi guys, find errors in code. It is not showing the output | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 3

Hi guys, find errors in code. It is not showing the output

https://code.sololearn.com/WSGv9DRRgiyo/?ref=app

18th Oct 2020, 9:17 AM
Sahil Chib
Sahil Chib - avatar
2 Answers
+ 2
if (packageWeight<"2.5") { additinalCharge="2"; } else if (packageWeight>"2.5") { if (packageWeight<"5") additinalCharge= "3"; else{ if(packageWeight>"5") additinalCharge= "4"; } } The above piece of code was missing some if else and curly brackets which I have added, Also i get another error afterwards, that there is no function like parsefloat
18th Oct 2020, 9:23 AM
Abhay
Abhay - avatar
+ 1
Abhay where to add parsefloat
18th Oct 2020, 9:33 AM
Sahil Chib
Sahil Chib - avatar