Skip to content

Daily ⭐ CodeWithAkash ⭐ is an initiative to do daily coding. The daily code started on 24 May 2021 πŸ§‘β€πŸ’» . Selected Most Important questions πŸ’― will be uploaded here with optimized solutions in the coming time. If one practices these questions then he/she will be ready to crack any big company. πŸ’₯ πŸ’― Give us a ⭐ if you like the initiative.

Notifications You must be signed in to change notification settings

Akash-goyal-github/CodeWithAkash

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ’― πŸ’₯ Daily codeWithAkash πŸ’₯πŸ’―



Topics 😎


βœ… Arrays βœ… Matrix

βœ… String βœ… Bit Manipulation

βœ… Searching & Sorting βœ… Linked List





Day Problem Solution Link Difficulty
D-1 Reverse the array https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-1/Problem-1.java Beginner
D-1 Find minimum and maximum element in an array https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-1/Problem-2.java Beginner
D-1 Kth smallest element https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/Day-1/Problem-3.java Beginner
D-1 Sort an array of 0s, 1s and 2s https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-1/Problem-4.java Beginner
D-1 Move all negative elements to end https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-1/Problem-5.java Beginner
D-2 Union of two arrays https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-2/Problem-1.java Beginner
D-2 Cyclically rotate an array by one https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-2/Problem-2.java Beginner
D-2 Find Largest contiguous Subarray https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-2/Problem-3.java Medium***
D-3 Minimize the Heights I https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-3/Problem-1.java Advanced
D-3 Minimize the Heights II https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-3/Problem-2.java Advanced***
D-3 Minimum number of jumps https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-3/Problem-3.java Medium***
D-4 Find the Duplicate Number https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-4/Problem-1.java Medium***
D-4 Merge 2 sorted Array without Using extra space https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/Day-4/Problem-2.java Medium***
D-4 Kadane's Algorithm https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-4/Problem-3.java Medium***
D-5 Merge Intervals https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-5/Problem-1.java Medium
D-5 Next Permutation https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-5/Problem-2.java Medium***
D-5 Count Inversion https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-5/Problem-3.java Advanced
D-6 Best Time to Buy and Sell Stock https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-6/Problem-1.java Beginner
D-6 Count pairs with given sum https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-6/Problem-2.java Medium***
D-6 Common elements https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-6/Problem-3.java Easy
D-7 Rearrange the array in alternating positive and negative items with O(1) extra space https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-7/Problem-1.java Medium
D-7 Subarray with 0 sum https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-7/Problem-2.java Medium***
D-7 Find factorial of a large number https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-7/Problem-3.java Medium***
D-8 find maximum product subarray https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-8/Problem-1.java Medium***
D-8 Longest consecutive subsequence https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-8/Problem-2.java Medium***
D-8 Given an array of size n and a number k, find all elements that appear more than " n/k " times https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-8/Problem-3.java Beginner***
D-9 Maximum Profit https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-9/Problem-1.java Medium***
D-9 Array Subset of another array https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-9/Problem-2.java Beginner
D-9 Triplet Sum in Array https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-9/Problem-3.java Medium***
D-10 Trapping Rain Water https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-10/Problem-1.java Medium***
D-10 Chocolate Distribution Problem https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-10/Problem-2.java Beginner
D-10 Smallest subarray with sum greater than x https://github.com/Akash-goyal-github/CodeWithAkash/tree/main/1.%20Arrays/Day-10/Problem-3.java Medium***
D-11 Three way partitioning https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-11/Problem-1.java Medium***
D-11 Minimum swaps and K together https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-11/Problem-2.java Medium***
D-11 Palindromic Array https://github.com/Akash-goyal-github/CodeWithAkash/tree/main/1.%20Arrays/Day-11/Problem-3.java Beginner
D-12 Find the median https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-12/Problem-1.java Medium***
D-12 Median of 2 Sorted Arrays of Different Sizes https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/1.%20Arrays/Day-12/Problem-2.java Advanced***

Top πŸ”




Day Problem Solution Link Difficulty
D-1 Spirally traversing a matrix https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/2.%20Matrix/Day-1/Problem-1.java Medium***
D-1 Search a 2D Matrix https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/2.%20Matrix/Day-1/Problem-2.java Easy***
D-1 Median in a row-wise sorted Matrix https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/2.%20Matrix/Day-1/Problem-3.java Medium***
D-2 Row with max 1s https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/2.%20Matrix/Day-2/Problem-1.java Easy***
D-2 Print elements in sorted order using row-column wise sorted matrix https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/2.%20Matrix/Day-2/Problem-2.java Easy***
D-2 Maximum size rectangle https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/2.%20Matrix/Day-2/Problem-3.java Medium***
D-3 Find a specific pair in matrix https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/2.%20Matrix/Day-3/Problem-1.java Medium***
D-3 Rotate matrix by 90 degrees https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/2.%20Matrix/Day-3/Problem-2.java Medium***
D-4 Kth smallest element in a row-cpumn wise sorted matrix https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/2.%20Matrix/Day-4/Problem-1.java Medium***
D-4 Common elements in all rows of a given matrix https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/2.%20Matrix/Day-4/Problem-2.java Easy***

Top πŸ”




Day Problem Solution Link Difficulty
D-1 Reverse a String https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/3.%20String/Day-1/Problem-1.java Beginner
D-1 Check whether a String is Palindrome or not https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/3.%20String/Day-1/Problem-2.java Beginner
D-1 Print all the duplicates in the input string https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/3.%20String/Day-1/Problem-3.java Beginner***
D-2 First Repeated Character in a string https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/3.%20String/Day-2/Problem-1.java Beginner***
D-2 Write a Code to check whether one string is a rotation of another https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/3.%20String/Day-2/Problem-2.java Easy***
D-2 Write a Program to check whether a string is a valid shuffle of two strings or not https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/3.%20String/Day-2/Problem-3.java Advanced***
D-3 Count and Say https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/3.%20String/Day-3/Problem-1.java Easy***

Top πŸ”




Day Problem Solution Link Difficulty
D-1 Count set bits in an integer https://github.com/Akash-goyal-github/CodeWithAkash/tree/main/4.%20Bit%20Manupulation/Day-1/Problem-1.java Easy
D-1 Find the two non-repeating elements in an array of repeating elements https://github.com/Akash-goyal-github/CodeWithAkash/tree/main/4.%20Bit%20Manupulation/Day-1/Problem-2.java Medium***
D-1 Count number of bits to be flipped to convert A to B https://github.com/Akash-goyal-github/CodeWithAkash/tree/main/4.%20Bit%20Manupulation/Day-1/Problem-3.java Easy
D-2 Count total set bits in all numbers from 1 to n https://github.com/Akash-goyal-github/CodeWithAkash/tree/main/4.%20Bit%20Manupulation/Day-2/Problem-1.java Medium***
D-2 Power of 2 https://github.com/Akash-goyal-github/CodeWithAkash/tree/main/4.%20Bit%20Manupulation/Day-2/Problem-2.java Easy
D-2 Find position of the only set bit https://github.com/Akash-goyal-github/CodeWithAkash/tree/main/4.%20Bit%20Manupulation/Day-2/Problem-3.java Easy
D-3 Copy set bits in a range https://github.com/Akash-goyal-github/CodeWithAkash/tree/main/4.%20Bit%20Manupulation/Day-3/Problem-1.java Advanced***
D-3 Divide two integers without using multiplication, division and mod operator https://github.com/Akash-goyal-github/CodeWithAkash/tree/main/4.%20Bit%20Manupulation/Day-3/Problem-1.java Advanced***
D-4 Calculate square of a number without using *, / and pow() https://github.com/Akash-goyal-github/CodeWithAkash/tree/main/4.%20Bit%20Manupulation/Day-3/Problem-1.java Easy***
D-4 Power Set https://github.com/Akash-goyal-github/CodeWithAkash/tree/main/4.%20Bit%20Manupulation/Day-3/Problem-1.java Medium***

Top πŸ”




Day Problem Solution Link Difficulty
D-1 Find first and last positions of an element in a sorted array https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-1/Problem-1.java Easy***
D-1 Find a Fixed Point (Value equal to index) in a given array https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-1/Problem-2.java Easy
D-1 Search in Rotated Sorted Array https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-1/Problem-3.java Medium***
D-2 square root of an integer https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-2/Problem-1.java Easy
D-2 Maximum and minimum of an array using minimum number of comparisons https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-2/Problem-2.java Easy*
D-2 Optimum location of point to minimize total distance https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-2/Problem-3.java Advanced***
D-3 Find the repeating and the missing https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-3/Problem-1.java Medium***
D-3 find majority element https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-3/Problem-2.java Easy***
D-3 Searching in an array where adjacent differ by at most k https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-3/Problem-3.java Easy***
D-4 find a pair with a given difference https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-4/Problem-1.java Easy***
D-4 find four elements that sum to a given value https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-4/Problem-2.java Advanced***
D-4 Stickler Thief (maximum sum such that no 2 elements are adjacent) https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-4/Problem-3.java Medium***
D-5 Count triplet with sum smaller than a given value https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-5/Problem-1.java Easy***
D-5 merge 2 sorted arrays https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-5/Problem-2.java Medium***
D-5 print all subarrays with 0 sum https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-5/Problem-3.java Medium***
D-6 Product array puzzle https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/5.%20Searching%20%26%20Sorting/Day-6/Problem-1.java Easy

Top πŸ”




Day Problem Solution Link Difficulty
D-1 Write a Program to reverse the Linked List https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-1/Problem-1.java Medium***
D-1 Reverse a Linked List in group of Given Size https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-1/Problem-2.java Advanced**
D-1 Rotate a Linked List https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-1/Problem-3.java Medium***
D-2 Detect Loop in linked list https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-2/Problem-1.java Easy***
D-2 Remove loop in Linked List https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-2/Problem-2.java Advanced***
D-2 Add two numbers represented by linked lists https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-2/Problem-3.java Medium***
D-3 Intersection Point in Y Shapped Linked Lists https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-3/Problem-1.java Easy***
D-3 Pairwise swap elements of a linked list https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-3/Problem-2.java Medium***
D-3 Middle of the Linked List https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-3/Problem-3.java Easy***
D-3 Flatten a Linked List https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-3/Problem-4.java Medium***
D-4 Sort a LL of 0's, 1's and 2's https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-4/Problem-1.java Easy***
D-4 Nth node from end of linked list https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-4/Problem-2.java Easy***
D-4 Implement Stack using Linked List https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-4/Problem-3.java Medium***
D-4 Merge two sorted Linked list https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-4/Problem-4.java Easy***
D-5 Implement Queue using Linked List https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-5/Problem-1.java Medium***
D-5 Delete without head pointer https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-5/Problem-2.java Medium***
D-5 Check if Linked List is Palindrome https://github.com/Akash-goyal-github/CodeWithAkash/blob/main/6.%20Linked%20List/Day-5/Problem-3.java Easy***

Top πŸ”



About

Daily ⭐ CodeWithAkash ⭐ is an initiative to do daily coding. The daily code started on 24 May 2021 πŸ§‘β€πŸ’» . Selected Most Important questions πŸ’― will be uploaded here with optimized solutions in the coming time. If one practices these questions then he/she will be ready to crack any big company. πŸ’₯ πŸ’― Give us a ⭐ if you like the initiative.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages