Aman Singh
@amansinghberra
Followers
150
Following
320
Media
62
Statuses
164
MERN Stack Developer | Full-Stack JavaScript Developer | React & Node.js | Typescript
Indian
Joined February 2025
🚀Day 64 of #100DayOfCode • Today's problem: Combination Sum • Approach: Use backtracking/recursion. • Time Complexity: Exponential in nature (backtracking). #DSA #LeetCode #cpp #CodingChallenge
0
0
16
🚀 Day 63 of #100DaysOfCode Today’s problem: XOR of Numbers in a Given Range • Approach : Use the pattern of XOR from 1..n. • Time Complexity: O(1) #Coding #DSA #LeetCode #100DaysOfCodeChallenge
1
0
18
🚀Day 62 of #100DaysOfCode Today's Problem : Single Number - III • Approach : Hash Map Counting , Count frequency of each number, Collect those with count = 1, Sort and return. • Time Complexity: O(n) #DSA #cpp #LeetCode #CodingChallenge
0
0
5
🚀 Day 60 & 61 of #100DaysOfCode Today's Problem: 1. Power Set (Bit Manipulation) • Approch - Use bitmasking • Time Complexity: O(n * 2^n) 2.Divide Two Numbers without Multiplication and Division • Approch - Use bit manipulation • Time Complexity: O(log n) #DSA
5
0
13
🚀Day 59 of #100DaysOfCode Today's Problem: Minimum Bit Flips to Convert Number • Approach: XOR start and goal to find differing bits. Count the number of 1s in the XOR result . • Time Complexity: O(1) #DSA #cpp #Leetcode #IndependenceDay #CodingChallenge
0
0
10
🚀 Day 58 of #100daysofcoding Today's Problem: Count subarrays with given XOR K • Approach: Use a prefix XOR at each step, calculate x = current_xor ^ k. Add the count of x in the map to the answer. Update the map with the current prefix XOR. • Time Complexity: O(n) #DSA #CPP
0
0
7
🚀Day 57 of #100DaysOfCode Problem: Count subarrays with a given sum • Approch : Using prefix sums + hashing to efficiently track and count valid subarrays • Time Complexity : O(n) #DSA #Cpp #PrefixSum #Hashing #ProblemSolving #Leetcode
4
0
17
🚀 Day 56 of #100DaysOfCode Today's Problem: Longest Consecutive Sequence in an Array • Approach: Store all elements in a hash set, Start counting only if num-1 doesn’t exist , Expand until sequence breaks • Time Complexity: O(n) #DSA #Cpp #Hashing #LeetCode #CodingChallenge
1
0
7
🚀Day 54 & 55 of #100DaysOfCode • Count All Subsequences with Sum K, Find the number of non-empty subsequences whose sum equals a given K. • Check if a Subsequence Exists with Sum K Determine if there’s at least one subsequence whose sum equals K. #DSA #LeetCode #cpp #NuNew
2
0
12
🚀 Day 53 of #100DaysOfCode Today's Problem: Find the Nth Root of a Number using Binary Search. • Nth root of M → number X such that X^N = M, If no integer exists, return -1. • Approach: Search space from 1 to M, check mid via pow() function. #DSA #Cpp #LeetCode
4
1
13
🚀 Day 52 of #100DaysOfCode Today's Problem: Search in a Rotated Sorted Array – I • Key idea: Identify which half of the array is sorted. Decide whether to search left or right based on the target. • Time Complexity: O(log n) #DSA #Cpp #LeetCode #CodingChallenge
3
0
11
🚀 Day 51 of #100DaysOfCode Today's Problem: Find the First and Last Occurrence • Used Binary Search to find: → First occurrence (move left on match) → Last occurrence (move right on match) •Time complexity : O(log n) #DSA #cpp #BinarySearch #CodingChallenge #LeetCode
1
0
8
🚀 Day 50 of #100DaysOfCode Today's Problem: Find the Floor and Ceil of a number in a sorted array, Floor → greatest element ≤ x, Ceil → smallest element ≥ x • Approch: Used linear scan to update values while traversing #DSA #Cpp #ProblemSolving #CodingChallenge
1
0
10
Day 49 of #100DaysOfCoding Today's Problem: Search Insert Position • Problem: Given a sorted array and a target, return the index if found. If not return the position where it should be inserted. • Approch: Binary Search • Time Complexity: O(logn) #coding #DSA #Leetcode #Cpp
0
0
16
🚀 Day 48 of #100DaysOfCode Today's Problem: 4 Sum (Leetcode Medium) • Approach: Sort the array, Use 2 nested loops + 2 pointers, Skip duplicates to ensure uniqueness • Time Complexity: O(n³) #Leetcode #DSA #Coding #CodeNewbie #Cplusplus #100DaysChallenge
2
0
19
Day 47 of #100DaysOfCode Today's Problem: 3 Sum Problem (#LeetCode15) • Approach: Sorted the array, Fixed one element and used the two-pointer technique to find the remaining pair, Skipped duplicates to ensure unique triplets #DSA #ThreeSum #ArrayProblem #Cpp #CodingChallenge
2
1
24
Day 46 of #100DaysOfCode Today's Problem: Rotate Matrix by 90° Clockwise • Approach:- 1: Transpose the matrix 2: Reverse each row OR Used a temp matrix to understand mapping: rotated[j][n - i - 1] = matrix[i][j] #DSA #MatrixManipulation #cpp #LeetCode #CodingChallenge
2
0
7
🚀Day 45 of #100DaysOfCode Today's Problem: Pascal’s Triangle I • Approach: Each value = nCr, i.e., combination of (r - 1) choose (c - 1) • Used an optimized method to compute combinations without factorials for better performance. #CodingChallenge #DSA #Cpp #LeetCode #DS
2
0
15
Day 44 of #100DaysOfCode Today's Problem: Print the matrix in spiral manner • Approach: Use four pointers top, bottom, left, right. Traverse in order: left to right, top to bottom, right to left, and bottom to top. Shrink the boundaries after each direction #Algorithms #DSA
1
0
10
🚀 Day 43 of #100DaysOfCode Today’s problem: Rearrange Array Elements by Sign • Implemented using extra space with two vectors for positives and negatives. • Time Complexity : O(N+N/2) #DSA #Cplusplus #100DaysChallenge #TakeUForward #LeetCode #Arrays #CodingDaily
1
0
9