+ 1

Hey please help me to correct this code! Why it gives wrong output. the same code i wrote for java which runs perfectly

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

14th Nov 2018, 1:10 AM
{ sood(Hemant , Prakash); }
{ sood(Hemant , Prakash); } - avatar
5 odpowiedzi
+ 2
It's just the line 8...Correct it and everything else seems fine :)
14th Nov 2018, 2:33 AM
Jerome Talluri
Jerome Talluri - avatar
+ 2
you said right i have to convert string into int using ParseInt. Thanks bro
14th Nov 2018, 3:00 AM
{ sood(Hemant , Prakash); }
{ sood(Hemant , Prakash); } - avatar
+ 1
The .value getter returns a string. Parse a, b, c to integer. I'm not sure line 8 is intended or not, but I'd suggest you remove the assignment to a. https://code.sololearn.com/WnZO4dk3X9RK/?ref=app
14th Nov 2018, 1:19 AM
Hoàng Nguyễn Văn
Hoàng Nguyễn Văn - avatar
+ 1
Hemant Prakash so it's still not working?
14th Nov 2018, 2:57 AM
Hoàng Nguyễn Văn
Hoàng Nguyễn Văn - avatar
- 1
i fixed line 8 but still not give correct output
14th Nov 2018, 2:55 AM
{ sood(Hemant , Prakash); }
{ sood(Hemant , Prakash); } - avatar