Vidya Shreetechwithvidya.hashnode.dev·Mar 6, 2024How to approach any recursion problemBefore we come to the approach lets understand recursion by a small example: Recursion is like opening a nesting doll. Each time you open one, there's a smaller doll inside. You keep going until you reach the smallest doll, just like solving smaller ...Discuss·3 likesRecursion
Emmanuel Inegbenosekizzy.hashnode.dev·Feb 22, 2024Demystifying Recursion - Part 2In the Part 1 of this series, we set the tone for understanding recursion at a fundamental level. However, it would be nice to actually gain an intuition for practical problems that are easily solved by recursion and hardly solved otherwise. In this ...Discuss·12 likes·51 readsRecursion
Emmanuel Inegbenosekizzy.hashnode.dev·Feb 5, 2024Demystifying Recursion - Part 1While learning how to program, recursion was the most difficult programming concept I encountered because not only does it seem cryptic, it seems like a leaky abstraction. You can barely gain a mental picture of how it works and when to make use of i...Bosiipo and 1 other are discussing this2 people are discussing thisDiscuss·12 likes·94 readsProgramming Tips
Sawan Badhwarsawan1367.hashnode.dev·Nov 15, 2023Josephus ProblemContinuing, my 100-day DSA journey. I encountered a deadly problem. In this problem, the last survivor claims victory. Like in the picture above, a group of friends, standing in a circle and one among them is holding a sword. The person with the swor...Discuss·10 likesRecursion
Sirisha Challagirisirishachallagiri.hashnode.dev·Nov 15, 2023Factorial of a numberFactorial of a non-negative number is the multiplication of all positive numbers that are smaller than are equal to n. Formula: n! = n*(n-1)\(n-2)*... 2\1 n=5 => 5*4*3*2*1 n=5 => 1*2*3*4*5 factorial of 5 is 120 0! = 1 Factorial using for loop: public...Discuss·1 likeCode With SiriJava
Sawan Badhwarsawan1367.hashnode.dev·Nov 14, 2023Day 15 of DSA ChallengeRise and Shine. One more day playing with recursion. I tried solving two new problems that I found out. However, I wasn't able to solve the second one. But still, I got this one down. In this case, I was asked to remove the middle element of the stac...DiscussStacks
Sirisha Challagirisirishachallagiri.hashnode.dev·Nov 10, 2023Reverse of a stringMethod 1: public class StringReverse { public static void main(String[] args) { String s = "code with siri"; String str=""; System.out.println("Original"+s); for(int i=s.length()-1;i>=0;i--){ str = str+s.charAt(i); } S...Discuss·1 like·28 readsCode With SiriJava
Sawan Badhwarsawan1367.hashnode.dev·Nov 9, 2023Continuing with what's leftHello! guys. As you guys know we were following freecodecamps' video for a better understanding for the concept of recursion. Today, we'll be completing what's left of that session. I invite you all to attend this wonderful and knowledgeable session ...DiscussRecursion
Sawan Badhwarsawan1367.hashnode.dev·Nov 8, 2023Catching UpGood Evening to all my dear friends. Today, I'm back with nothing new, sad isn't it but nothing can be done for now. I'm a college student and for the previous 2 months, I was busy training girls' and boys' handball teams for the upcoming inter-colle...Discuss·10 likesRecursion
Sawan Badhwarsawan1367.hashnode.dev·Nov 7, 2023FreeCodeCampRecursion is one enjoyable yet lengthy topic to study. But sharing it with you guys makes me feel less work and keep on going at my task. Today, here after practicing so many questions based on recursion, we'll be revising the basics of recursion aga...Discuss·11 likesRecursion