code -> https://ide.codingblocks.com/s/305207
code2-> https://ide.codingblocks.com/s/305209
my both codes are not working please tell me the error in both of my codes.
code -> https://ide.codingblocks.com/s/305207
code2-> https://ide.codingblocks.com/s/305209
my both codes are not working please tell me the error in both of my codes.
I have edited one of your code and it is working fine.Your logic is correct,Just use long long int instead of int.
If you think you doubt is resolved then please mark it as resolved and give your feedback:)
Thanks