October LunchTime UNofficial Editorials (First two problems) Revised

maximum value of n is 100000 so it remain in the int range so it is not the reason of getting RE(NZEC) . So why i am getting RE(NZEC).please help!
thank you.

Probably weak test casesā€¦

N is the number of digits in given problemā€¦
Means the number can be upto 10^(10^5), way beyond int and long range

Mate

Try following tesr case

1

10000200000000000

Thanksā€¦

PS: I am a first year student, not yet CA. Long way to go!!

Mate, You cannot take a number with 10^5 digits in int data type. You have to input it as a string.

Try following test case.

1

10000200000000000

Second thing, Your solution try to delete one digit, check the resultant number. This way, Your solution has time complexity O(N^2), which wonā€™t even pass the time limit for number of digits upto 10^3.

That link was wrong! I changed it:D

But i tested my code on clion and codechef compiler, it didnā€™t printed any leading zeroes.Could you please specify the test case in which it printed leading zeroes.

The link that I gave before was not working , Sorry for thatā€¦
Now I updated the link

Try the test case

1

3602

Correct answer is 360

PS:what if last two digits are both even and last digit on deletion gives the maximum answer.

Enjoy coding :smiley:

Hey

Try the following test case

1

630

Correct answer is 60.

Enjoy coding :smiley: (PS:i wonā€™t tell the bug)

Try test case

1

660

Correct answer 66, your answer 60

thanks,buddy

You cannot take a number with 10^5 digits as int data type. You have to take it as string.

Try following test case

1

11100000000000000000000

Enjoy

thanks much!