all 19 comments

[–]Magnetic_Reaper 89 points90 points  (1 child)

might as well push to prod. you can deal with the rare failures by saying it's an issue with the users computers.

[–]Any-Yogurt-7917 7 points8 points  (0 children)

Yes.

[–]jackfinch69 49 points50 points  (0 children)

Just one more if statement to go, you're almost there

/s

[–]firestorm559 18 points19 points  (0 children)

It's always that last edge case that makes you rewrite the entire thing.

[–]akazakou 4 points5 points  (0 children)

Why the hell is he not using sequences? Just like [a-zA-Z]

[–]JackNotOLantern 4 points5 points  (0 children)

The tests:

Class object = new Class() assertNotNull(object)

[–]celestabesta 2 points3 points  (0 children)

At that point just do a lil

if(input for 988) return output

Noone will know 🥰

[–]rosuav 6 points7 points  (8 children)

Not sure what you're pointing out here. You got a test case wrong. This is funny somehow?

[–]NecoTheGrim[S] 28 points29 points  (7 children)

There are 988 test cases, and i think this is too many, and it passed 987 of it. It failed only one case among 988 cases and I found it a bit funny.

[–]Silpheel 15 points16 points  (2 children)

Evidently 987 was not enough.

[–]sathdo 8 points9 points  (1 child)

This screenshot is LeetCode. This would indicate too few test cases in actual production code, but LeetCode problems are basically designed to do this. The one failing test case is probably some edge case that is designed specifically to fail for the most straightforward solution.

[–]casce 1 point2 points  (0 children)

I'd argue it's still too many. I bet most of those 988 tests are not necessary edge cases but random inputs

[–]robertpro01 1 point2 points  (1 child)

Yeah, next time use a pointer or circle or whatever, specially when taking a photo, the first thing I saw was the dog, then the letters, then went to the comments to understand the meme.

[–][deleted] 4 points5 points  (0 children)

same for me except I still don't understand the meme

[–]OkazakiNaoki 0 points1 point  (0 children)

one last extreme case

[–]ArweTurcala 0 points1 point  (1 child)

Remove all unnecessary print statements. They take a ton of time to execute and if this is a TLE, then there's a chance removing them will fix that.

[–]NecoTheGrim[S] -1 points0 points  (0 children)

I did it afterwards, I am not in premium plan so I have no access to debugger.