-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Recursion
Mission Peace edited this page Oct 19, 2016
·
3 revisions
- Generate all combination of size k and less of adjacent numbers - AllAdjacentCombination.java
- Generate all bracket combination, check if brackets open and closing is correct or not - Bracketology.java
- Given an array of strings, find if the given strings can be chained to form a circle. A string X can be put before another string Y in circle if the last character of X is same as first character of Y - ChainWordsToFormCircle.java
- Generate all combinations - Combination.java
- Generate all combination of size k - CombinationOfSizeK.java
- Generate all combination which prints star in place of absent characters - CombinationWithStar.java
- Consider a coding system for alphabets to integers where ‘a’ is represented as 1, ‘b’ as 2, .. ‘z’ as 26. Given an array of digits (1 to 9) as input, write a function that prints all valid interpretations of input array - InterpretationOfArray.java
- Generate all possible string combinations of a given phone number - KeyPadPermutation.java
- Minimum edits required to generate reverse polish notation - MinimumEditForReversePolishNotation.java
- Given a board of size nxn and n queens, place them on the board so that they don't attack each other - NQueenProblem.java
- Given two strings check if they are one distance away from each other where you can delete,edit or add characters - OneEditApart.java
- Print all paths from top left corner to bottom right corner - PrintAllPathFromTopLeftToBottomRight.java
- Given an array find number of interpretations possible for combinations of adjacent characters - PrintArrayInAdjacentWay.java
- Print array in tree fashion - PrintArrayInCustomizedFormat.java
- Permutation of string in both sorted and unsorted order - StringPermutation.java stringpermutation.py StringPermutationRotation.java
- Given two strings, generate all interleavings of these strings - StringInterleaving.java
- Shuffle a character array so that no two repeated characters are together. [FancyShuffle.java] (https://github.com/mission-peace/interview/blob/master/src/com/interview/recursion/FancyShuffle.java)
- Given an input and total, print all combinations with repetitions in this input which sums to given total. PrintSumCombination.java
- Given a List of List of Strings. Print cartesian product of List. WordCombination.java
- Given input of unique elements and pair among those elements. How many minimum swaps are needed to arrange pair adjacent to each other. SetPairTogether.java setpairtogether.py
- Given input string e.g 123 and target e.g 6, place operator +, - and * so that 123 evaluates to 6. OperatorAdditionForTarget.java
- Print all permutations of given input array - PrintAllSubsequence.java
- Reconstruct itinerary based on ticket - ReconstructItinerary.java
- Remove the minimum number of invalid parentheses in order to make the input string valid. Return all possible results - RemoveInvalidParenthesis.java
- Sudoku solver - SudokuSolver.java
- Restore ip address - RestoreIPAddresses.java
- Find absolute longest path in directory structure represented by \n and \t - LongestAbsolutePath.java