The repo consists of solutions to numerous problems using different data structures and algorithms, all coded in Java. It also contains solutions to HackerRank problems which I have solved so far and questions from Cracking the Coding Interview Book (6th Edition).
You can also refer to my Java Notes for a quick refresh on the Java concepts. Lastly, feel free to connect with me on Twitter for any queries or concerns. All the best!
- Basic Practice:
- Arrays
- ArrangeNosToFormBiggestNo
- BooleanMatrix
- CelebrityProblem
- ConsecutiveElements
- CountDivisors
- CountSmallerElementsOnRHS
- DistinctPairs
- DuplicatesInArray
- DuplicatesInArrayWithinKDistance
- EqualProbabilityRandomNoGenerator
- EquilibriumIndex
- FixedPoint
- FlattenArray
- IntersectionAndUnionOf2SortedArrays
- InversionsInArray
- KLargestElements
- KthLargestElement
- LargestProductContiguousSubArray
- LargestSumContiguousSubArray
- LeadersInArray
- LongestBitonicSubArray
- LongestConsecutiveSubsequence
- MajorityElement
- MajorityElementInSortedArray
- MatrixInSpiral
- MaxDiffWithLargerElementAfterSmallerElement
- MaxInAllSubArrays
- MaxIndexDiff
- MaxMinWithMinComparisons
- MaxSpan
- MaximumSizeSquareSubMatrix
- MaximumSumNonAdjacentSubSequence
- MedianOfStream
- MedianOfTwoSortedArrays
- MergeArrayOfNIntoArrayOfMPlusN
- MinimumDistanceBetweenTwoNos
- MissingAndRepeatingElements
- MissingNumber
- NextGreaterElement
- NextLargerNumber
- NthSmallestNumber
- NumberOccurringOddTimes
- OccurrencesInSortedArray
- PairDiff
- PairSum
- PivotedBinarySearch
- ProductArrayPuzzle
- ReservoirSampling
- ReverseArray
- RotateArray
- RotateMatrixBy90Degrees
- RotatedIndex
- SearchInSorted2DArray
- Segregate0s1sAnd2s
- Segregate0sAnd1s
- SegregateEvenAndOddNos
- SmallestAndSecondSmallest
- SmallestMissingNumber
- SortedSubSequence
- SubArrayOfSum
- SubsetOfArray
- SymmetricDifference
- TripletOfSum
- TwoElementsSumClosestToZero
- TwoRepeatingElements
- TwoStacksInOneArray
- UnsortedSubArray
- Backtracking
- Bits
- Blockchain Demo
- Dynamic Programming
- Graphs
- Java 8
- Linked Lists
- Miscellaneous
- Permutations
- Searching
- Sorting
- Stacks
- Strings
- Threads
- Trees
- Arrays
- Cracking the Coding Interview:
- LeetCode.
- HackerRank.
Java version 1.8.0_172
Java(TM) SE Runtime Environment (build 1.8.0_172-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.172-b11, mixed mode)
IntelliJ IDEA 2018.1.4 (Ultimate Edition)
MacBook Pro
2.5 GHz Intel Core i7
16 GB 1600 MHz DDR3