Welcome to CS-Student!

The mission of this website is to share STEM knowledge I have experienced


All Posts

  • Bash Scripts Basic

    The term “shell” encompasses any software program that offers a command-line interface to interact with an operating system. Among various types of shells, “Bash” is a popular one…

    Continue Reading

  • Recursion : how to change from non-tail to tail

    (1) Introduce an accumulator parameter in the recursive function. Initialize the accumulator with a value that satisfies two conditions a) when the smallest value is passed from main()…

    Continue Reading

  • Recursion: Enhance performance through Memoization and Tabulation

    Memoization or memoisation is an optimization technique used in computing to accelerate program execution. It involves storing the results of costly function calls, particularly to pure functions, and…

    Continue Reading

  • Tail and non-tail recursive function

    The provided example showcases the reversal of digits within an integer using two different methods: non-tail recursion and tail recursion. The main() function calls the reverseDigit() function, implemented…

    Continue Reading

  • C++ Tail Recursion

    Tail recursion is a special case of recursion where the recursive call is the last operation performed in a function. In other words, the recursive call is in…

    Continue Reading

  • C++ Recursion: Pros and Cons

    Pros of Recursion: Cons of Recursion: When considering recursion, it’s important to assess problem requirements, input size, and performance constraints. While recursion can be powerful, it’s not always…

    Continue Reading