Day 19 – Recursion, Backtracking, and Math Logic
1. Subset Sum (Leetcode 78: Subsets)
Problem: Return all possible subsets (the power set) of a given array of distinct integers.
Intuition: At each index, we have two choices: include or exclude the current element.
void solve(int i, vector<int>& num...
sids-dsa-journal.hashnode.dev4 min read