Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @Test
- public void failedRecurions() throws Exception {
- int result = failedRecursion(0);
- Assert.assertTrue(result==10000);
- }
- private int failedRecursion(int i) {
- if (i==10000)
- return i;
- return failedRecursion(i++);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement