+ 4
[SOLVED] [C#] Help me debug my code (Keprekar's constant challenge).
I was trying out the solution for the easy difficulty for Keprekar's constant challenge and I have some bugs in my code. I'll greatly appreciate if someone can help me debug it. Post: https://www.sololearn.com/learn/6575/?ref=app Code: https://code.sololearn.com/cynVlRo0laP0/?ref=app
6 Respuestas
+ 4
Use this for line 37:
return KaprekarCalculator(_kaprekar, _max, _min);
And put some print statements in your code, like: Console.WriteLine(_kaprekar);
Console.WriteLine(_maxr);
Console.WriteLine(_min);
These values should have 4 digits, they have more than that.
+ 4
Solved it guys Paul Jacobs Jeya Mc
The major bug was in the ToNumber method. Thanks guys.
+ 3
Edho enala mudinjathu bro Jeya Mc 😁
+ 1
parvala illa. Bro intha alavukku coding eluthi irukinga
+ 1
yes bro its working 🙌 congrats 😇
0
okay bro coding mudichittu answer vantha sollunga naan paathu ethuna doubt na kettukiren😁😄😉