+ 2

Classes and objects

I tried my best but didn't got the answer can anyone tell me where did I went wrong https://code.sololearn.com/cCDYlz3YW95J/?ref=app

1st Nov 2021, 11:38 AM
Samaan Sayed
4 Answers
+ 1
https://code.sololearn.com/ct2eCg2IFcsw/?ref=app Fixed, if you have further questions, feel free to ask.
1st Nov 2021, 11:49 AM
[No Name]
[No Name] - avatar
+ 1
i fix your code and explain the problem inside : ) https://code.sololearn.com/cUJPCx73GA5m
1st Nov 2021, 1:11 PM
naor hasson
naor hasson - avatar
0
You didn't declare a return type for getl(). Edit: That's not all... Gimme a sec
1st Nov 2021, 11:42 AM
[No Name]
[No Name] - avatar
0
Line no:7 use len instead of getl as : len(string x,string y){ //constructer for class len Not getl(string x,string y){ //normal function
1st Nov 2021, 11:45 AM
Jayakrishna 🇼🇳