SYMBOL INDEX (10090 symbols across 1531 files) FILE: .github/workflows/scripts/check_structure.py function _is_java_file_properly_located (line 5) | def _is_java_file_properly_located(java_file: pathlib.Path) -> bool: function _find_misplaced_java_files (line 13) | def _find_misplaced_java_files() -> list[pathlib.Path]: FILE: src/main/java/com/thealgorithms/audiofilters/EMAFilter.java class EMAFilter (line 13) | public class EMAFilter { method EMAFilter (line 22) | public EMAFilter(double alpha) { method apply (line 35) | public double[] apply(double[] audioSignal) { FILE: src/main/java/com/thealgorithms/audiofilters/IIRFilter.java class IIRFilter (line 9) | public class IIRFilter { method IIRFilter (line 23) | public IIRFilter(int order) throws IllegalArgumentException { method setCoeffs (line 48) | public void setCoeffs(double[] aCoeffs, double[] bCoeffs) throws Illeg... method process (line 73) | public double process(double sample) { FILE: src/main/java/com/thealgorithms/backtracking/AllPathsFromSourceToTarget.java class AllPathsFromSourceToTarget (line 37) | @SuppressWarnings({"rawtypes", "unchecked"}) method AllPathsFromSourceToTarget (line 49) | public AllPathsFromSourceToTarget(int vertices) { method initAdjList (line 59) | private void initAdjList() { method addEdge (line 68) | public void addEdge(int u, int v) { method storeAllPaths (line 73) | public void storeAllPaths(int s, int d) { method storeAllPathsUtil (line 86) | private void storeAllPathsUtil(Integer u, Integer d, boolean[] isVisit... method allPathsFromSourceToTarget (line 114) | public static List> allPathsFromSourceToTarget(int verti... FILE: src/main/java/com/thealgorithms/backtracking/ArrayCombination.java class ArrayCombination (line 10) | public final class ArrayCombination { method ArrayCombination (line 11) | private ArrayCombination() { method combination (line 22) | public static List> combination(int n, int k) { method combine (line 41) | private static void combine(List> combinations, List List> combination(T[] arr, int n) { method backtracking (line 48) | private static void backtracking(T[] arr, int n, int index, TreeSe... FILE: src/main/java/com/thealgorithms/backtracking/CombinationSum.java class CombinationSum (line 8) | public final class CombinationSum { method CombinationSum (line 9) | private CombinationSum() { method combinationSum (line 13) | public static List> combinationSum(int[] candidates, int... method backtrack (line 25) | private static void backtrack(int[] candidates, int remaining, int sta... FILE: src/main/java/com/thealgorithms/backtracking/CrosswordSolver.java class CrosswordSolver (line 25) | public final class CrosswordSolver { method CrosswordSolver (line 26) | private CrosswordSolver() { method isValid (line 39) | public static boolean isValid(char[][] puzzle, String word, int row, i... method placeWord (line 63) | public static void placeWord(char[][] puzzle, String word, int row, in... method removeWord (line 82) | public static void removeWord(char[][] puzzle, String word, int row, i... method solveCrossword (line 99) | public static boolean solveCrossword(char[][] puzzle, Collection neighbors(int row, int column) { method countNeighbors (line 125) | static int countNeighbors(int row, int column) { method orphanDetected (line 145) | static boolean orphanDetected(int count, int row, int column) { FILE: src/main/java/com/thealgorithms/backtracking/MColoring.java class Node (line 15) | class Node { class MColoring (line 25) | public final class MColoring { method MColoring (line 27) | private MColoring() { method isColoringPossible (line 38) | static boolean isColoringPossible(ArrayList nodes, int n, int m) { FILE: src/main/java/com/thealgorithms/backtracking/MazeRecursion.java class MazeRecursion (line 11) | public final class MazeRecursion { method MazeRecursion (line 13) | private MazeRecursion() { method solveMazeUsingFirstStrategy (line 23) | public static int[][] solveMazeUsingFirstStrategy(int[][] map) { method solveMazeUsingSecondStrategy (line 37) | public static int[][] solveMazeUsingSecondStrategy(int[][] map) { method setWay (line 53) | private static boolean setWay(int[][] map, int i, int j) { method setWay2 (line 95) | private static boolean setWay2(int[][] map, int i, int j) { FILE: src/main/java/com/thealgorithms/backtracking/NQueens.java class NQueens (line 35) | public final class NQueens { method NQueens (line 36) | private NQueens() { method getNQueensArrangements (line 39) | public static List> getNQueensArrangements(int queens) { method placeQueens (line 45) | public static void placeQueens(final int queens) { method getSolution (line 67) | private static void getSolution(int boardSize, List> solu... method isPlacedCorrectly (line 102) | private static boolean isPlacedCorrectly(int[] columns, int rowIndex, ... FILE: src/main/java/com/thealgorithms/backtracking/ParenthesesGenerator.java class ParenthesesGenerator (line 9) | public final class ParenthesesGenerator { method ParenthesesGenerator (line 10) | private ParenthesesGenerator() { method generateParentheses (line 20) | public static List generateParentheses(final int n) { method generateParenthesesHelper (line 38) | private static void generateParenthesesHelper(List result, fin... FILE: src/main/java/com/thealgorithms/backtracking/Permutation.java class Permutation (line 10) | public final class Permutation { method Permutation (line 11) | private Permutation() { method permutation (line 20) | public static List permutation(T[] arr) { method backtracking (line 34) | private static void backtracking(T[] arr, int index, List res... method swap (line 52) | private static void swap(int a, int b, T[] arr) { FILE: src/main/java/com/thealgorithms/backtracking/PowerSum.java class PowerSum (line 13) | public class PowerSum { method powSum (line 22) | public int powSum(int targetSum, int power) { method sumRecursive (line 39) | private int sumRecursive(int remainingSum, int power, int currentNumbe... FILE: src/main/java/com/thealgorithms/backtracking/SubsequenceFinder.java class SubsequenceFinder (line 9) | public final class SubsequenceFinder { method SubsequenceFinder (line 10) | private SubsequenceFinder() { method generateAll (line 20) | public static List> generateAll(List sequence) { method backtrack (line 42) | private static void backtrack(List sequence, List currentSub... FILE: src/main/java/com/thealgorithms/backtracking/SudokuSolver.java class SudokuSolver (line 9) | public final class SudokuSolver { method SudokuSolver (line 15) | private SudokuSolver() { method solveSudoku (line 25) | public static boolean solveSudoku(int[][] board) { method solve (line 45) | private static boolean solve(int[][] board) { method isValidPlacement (line 77) | private static boolean isValidPlacement(int[][] board, int row, int co... method isNumberInRow (line 89) | private static boolean isNumberInRow(int[][] board, int row, int numbe... method isNumberInColumn (line 106) | private static boolean isNumberInColumn(int[][] board, int col, int nu... method isNumberInSubgrid (line 124) | private static boolean isNumberInSubgrid(int[][] board, int row, int c... method printBoard (line 143) | public static void printBoard(int[][] board) { FILE: src/main/java/com/thealgorithms/backtracking/UniquePermutation.java class UniquePermutation (line 16) | public final class UniquePermutation { method UniquePermutation (line 18) | private UniquePermutation() { method generateUniquePermutations (line 23) | public static List generateUniquePermutations(String input) { method backtrack (line 36) | private static void backtrack(char[] chars, boolean[] used, StringBuil... FILE: src/main/java/com/thealgorithms/backtracking/WordPatternMatcher.java class WordPatternMatcher (line 22) | public final class WordPatternMatcher { method WordPatternMatcher (line 23) | private WordPatternMatcher() { method matchWordPattern (line 33) | public static boolean matchWordPattern(String pattern, String inputStr... method backtrack (line 50) | private static boolean backtrack(String pattern, String inputString, i... FILE: src/main/java/com/thealgorithms/backtracking/WordSearch.java class WordSearch (line 37) | public class WordSearch { method dfs (line 49) | private boolean dfs(char[][] board, int x, int y, String word, int idx) { method exist (line 77) | public boolean exist(char[][] board, String word) { FILE: src/main/java/com/thealgorithms/bitmanipulation/BcdConversion.java class BcdConversion (line 20) | public final class BcdConversion { method BcdConversion (line 21) | private BcdConversion() { method bcdToDecimal (line 37) | public static int bcdToDecimal(int bcd) { method decimalToBcd (line 67) | public static int decimalToBcd(int decimal) { FILE: src/main/java/com/thealgorithms/bitmanipulation/BinaryPalindromeCheck.java class BinaryPalindromeCheck (line 13) | public final class BinaryPalindromeCheck { method BinaryPalindromeCheck (line 14) | private BinaryPalindromeCheck() { method isBinaryPalindrome (line 23) | public static boolean isBinaryPalindrome(int x) { method reverseBits (line 34) | private static int reverseBits(int x) { FILE: src/main/java/com/thealgorithms/bitmanipulation/BitRotate.java class BitRotate (line 14) | public final class BitRotate { method BitRotate (line 20) | private BitRotate() { method rotateLeft (line 38) | public static int rotateLeft(int value, int shift) { method rotateRight (line 68) | public static int rotateRight(int value, int shift) { FILE: src/main/java/com/thealgorithms/bitmanipulation/BitSwap.java class BitSwap (line 7) | public final class BitSwap { method BitSwap (line 8) | private BitSwap() { method bitSwap (line 21) | public static int bitSwap(int data, final int posA, final int posB) { FILE: src/main/java/com/thealgorithms/bitmanipulation/BitwiseGCD.java class BitwiseGCD (line 25) | public final class BitwiseGCD { method BitwiseGCD (line 27) | private BitwiseGCD() { method gcd (line 41) | public static long gcd(long a, long b) { method absOrThrowIfOverflow (line 90) | private static long absOrThrowIfOverflow(long x) { method gcd (line 103) | public static long gcd(long... values) { method gcdBig (line 126) | public static BigInteger gcdBig(BigInteger a, BigInteger b) { method gcdBig (line 137) | public static BigInteger gcdBig(long a, long b) { method gcd (line 144) | public static int gcd(int a, int b) { FILE: src/main/java/com/thealgorithms/bitmanipulation/BooleanAlgebraGates.java class BooleanAlgebraGates (line 8) | public final class BooleanAlgebraGates { method BooleanAlgebraGates (line 10) | private BooleanAlgebraGates() { type BooleanGate (line 17) | interface BooleanGate { method evaluate (line 24) | boolean evaluate(List inputs); class ANDGate (line 31) | static class ANDGate implements BooleanGate { method evaluate (line 32) | @Override class ORGate (line 47) | static class ORGate implements BooleanGate { method evaluate (line 48) | @Override class NOTGate (line 63) | static class NOTGate { method evaluate (line 70) | public boolean evaluate(boolean input) { class XORGate (line 79) | static class XORGate implements BooleanGate { method evaluate (line 80) | @Override class NANDGate (line 94) | static class NANDGate implements BooleanGate { method evaluate (line 95) | @Override class NORGate (line 105) | static class NORGate implements BooleanGate { method evaluate (line 106) | @Override FILE: src/main/java/com/thealgorithms/bitmanipulation/ClearLeftmostSetBit.java class ClearLeftmostSetBit (line 15) | public final class ClearLeftmostSetBit { method ClearLeftmostSetBit (line 16) | private ClearLeftmostSetBit() { method clearLeftmostSetBit (line 28) | public static int clearLeftmostSetBit(int num) { FILE: src/main/java/com/thealgorithms/bitmanipulation/CountBitsFlip.java class CountBitsFlip (line 20) | public final class CountBitsFlip { method CountBitsFlip (line 22) | private CountBitsFlip() { method countBitsFlip (line 38) | public static long countBitsFlip(long a, long b) { method countBitsFlipAlternative (line 60) | public static long countBitsFlipAlternative(long a, long b) { FILE: src/main/java/com/thealgorithms/bitmanipulation/CountLeadingZeros.java class CountLeadingZeros (line 13) | public final class CountLeadingZeros { method CountLeadingZeros (line 14) | private CountLeadingZeros() { method countLeadingZeros (line 25) | public static int countLeadingZeros(int num) { FILE: src/main/java/com/thealgorithms/bitmanipulation/CountSetBits.java class CountSetBits (line 9) | public final class CountSetBits { method CountSetBits (line 11) | private CountSetBits() { method countSetBits (line 23) | public static int countSetBits(int n) { method largestPowerOf2InNumber (line 53) | private static int largestPowerOf2InNumber(int n) { method countSetBitsNaive (line 68) | public static int countSetBitsNaive(int n) { FILE: src/main/java/com/thealgorithms/bitmanipulation/FindNthBit.java class FindNthBit (line 16) | public final class FindNthBit { method FindNthBit (line 24) | private FindNthBit() { method findNthBit (line 39) | public static int findNthBit(int num, int n) { FILE: src/main/java/com/thealgorithms/bitmanipulation/FirstDifferentBit.java class FirstDifferentBit (line 15) | public final class FirstDifferentBit { method FirstDifferentBit (line 16) | private FirstDifferentBit() { method firstDifferentBit (line 29) | public static int firstDifferentBit(int x, int y) { FILE: src/main/java/com/thealgorithms/bitmanipulation/GenerateSubsets.java class GenerateSubsets (line 12) | public final class GenerateSubsets { method GenerateSubsets (line 13) | private GenerateSubsets() { method generateSubsets (line 28) | public static List> generateSubsets(int[] set) { FILE: src/main/java/com/thealgorithms/bitmanipulation/GrayCodeConversion.java class GrayCodeConversion (line 16) | public final class GrayCodeConversion { method GrayCodeConversion (line 17) | private GrayCodeConversion() { method binaryToGray (line 26) | public static int binaryToGray(int num) { method grayToBinary (line 36) | public static int grayToBinary(int gray) { FILE: src/main/java/com/thealgorithms/bitmanipulation/HammingDistance.java class HammingDistance (line 13) | public final class HammingDistance { method HammingDistance (line 14) | private HammingDistance() { method hammingDistance (line 25) | public static int hammingDistance(int x, int y) { FILE: src/main/java/com/thealgorithms/bitmanipulation/HigherLowerPowerOfTwo.java class HigherLowerPowerOfTwo (line 19) | public final class HigherLowerPowerOfTwo { method HigherLowerPowerOfTwo (line 20) | private HigherLowerPowerOfTwo() { method nextHigherPowerOfTwo (line 29) | public static int nextHigherPowerOfTwo(int x) { method nextLowerPowerOfTwo (line 48) | public static int nextLowerPowerOfTwo(int x) { FILE: src/main/java/com/thealgorithms/bitmanipulation/HighestSetBit.java class HighestSetBit (line 20) | public final class HighestSetBit { method HighestSetBit (line 22) | private HighestSetBit() { method findHighestSetBit (line 37) | public static Optional findHighestSetBit(int num) { FILE: src/main/java/com/thealgorithms/bitmanipulation/IndexOfRightMostSetBit.java class IndexOfRightMostSetBit (line 12) | public final class IndexOfRightMostSetBit { method IndexOfRightMostSetBit (line 14) | private IndexOfRightMostSetBit() { method indexOfRightMostSetBit (line 25) | public static int indexOfRightMostSetBit(int n) { FILE: src/main/java/com/thealgorithms/bitmanipulation/IsEven.java class IsEven (line 8) | public final class IsEven { method IsEven (line 9) | private IsEven() { method isEven (line 11) | public static boolean isEven(int number) { FILE: src/main/java/com/thealgorithms/bitmanipulation/IsPowerTwo.java class IsPowerTwo (line 10) | public final class IsPowerTwo { method IsPowerTwo (line 11) | private IsPowerTwo() { method isPowerTwo (line 25) | public static boolean isPowerTwo(int number) { FILE: src/main/java/com/thealgorithms/bitmanipulation/LowestSetBit.java class LowestSetBit (line 8) | public final class LowestSetBit { method LowestSetBit (line 10) | private LowestSetBit() { method isolateLowestSetBit (line 19) | public static int isolateLowestSetBit(int n) { method clearLowestSetBit (line 30) | public static int clearLowestSetBit(int n) { FILE: src/main/java/com/thealgorithms/bitmanipulation/ModuloPowerOfTwo.java class ModuloPowerOfTwo (line 10) | public final class ModuloPowerOfTwo { method ModuloPowerOfTwo (line 11) | private ModuloPowerOfTwo() { method moduloPowerOfTwo (line 21) | public static int moduloPowerOfTwo(int x, int n) { FILE: src/main/java/com/thealgorithms/bitmanipulation/NextHigherSameBitCount.java class NextHigherSameBitCount (line 9) | public final class NextHigherSameBitCount { method NextHigherSameBitCount (line 10) | private NextHigherSameBitCount() { method nextHigherSameBitCount (line 25) | public static int nextHigherSameBitCount(int n) { FILE: src/main/java/com/thealgorithms/bitmanipulation/NonRepeatingNumberFinder.java class NonRepeatingNumberFinder (line 18) | public final class NonRepeatingNumberFinder { method NonRepeatingNumberFinder (line 19) | private NonRepeatingNumberFinder() { method findNonRepeatingNumber (line 28) | public static int findNonRepeatingNumber(int[] arr) { FILE: src/main/java/com/thealgorithms/bitmanipulation/NumberAppearingOddTimes.java class NumberAppearingOddTimes (line 23) | public final class NumberAppearingOddTimes { method NumberAppearingOddTimes (line 24) | private NumberAppearingOddTimes() { method findOddOccurrence (line 34) | public static int findOddOccurrence(int[] arr) { FILE: src/main/java/com/thealgorithms/bitmanipulation/NumbersDifferentSigns.java class NumbersDifferentSigns (line 16) | public final class NumbersDifferentSigns { method NumbersDifferentSigns (line 17) | private NumbersDifferentSigns() { method differentSigns (line 27) | public static boolean differentSigns(int num1, int num2) { FILE: src/main/java/com/thealgorithms/bitmanipulation/OneBitDifference.java class OneBitDifference (line 13) | public final class OneBitDifference { method OneBitDifference (line 14) | private OneBitDifference() { method differByOneBit (line 24) | public static boolean differByOneBit(int x, int y) { FILE: src/main/java/com/thealgorithms/bitmanipulation/OnesComplement.java class OnesComplement (line 11) | public final class OnesComplement { method OnesComplement (line 12) | private OnesComplement() { method onesComplement (line 22) | public static String onesComplement(String binary) { FILE: src/main/java/com/thealgorithms/bitmanipulation/ParityCheck.java class ParityCheck (line 16) | public final class ParityCheck { method ParityCheck (line 17) | private ParityCheck() { method checkParity (line 26) | public static boolean checkParity(int n) { FILE: src/main/java/com/thealgorithms/bitmanipulation/ReverseBits.java class ReverseBits (line 21) | public final class ReverseBits { method ReverseBits (line 22) | private ReverseBits() { method reverseBits (line 31) | public static int reverseBits(int n) { FILE: src/main/java/com/thealgorithms/bitmanipulation/SingleBitOperations.java class SingleBitOperations (line 21) | public final class SingleBitOperations { method SingleBitOperations (line 22) | private SingleBitOperations() { method flipBit (line 32) | public static int flipBit(final int num, final int bit) { method setBit (line 43) | public static int setBit(final int num, final int bit) { method clearBit (line 54) | public static int clearBit(final int num, final int bit) { method getBit (line 65) | public static int getBit(final int num, final int bit) { FILE: src/main/java/com/thealgorithms/bitmanipulation/SingleElement.java class SingleElement (line 13) | public final class SingleElement { method SingleElement (line 19) | private SingleElement() { method findSingleElement (line 32) | public static int findSingleElement(int[] arr) { FILE: src/main/java/com/thealgorithms/bitmanipulation/SwapAdjacentBits.java class SwapAdjacentBits (line 28) | public final class SwapAdjacentBits { method SwapAdjacentBits (line 29) | private SwapAdjacentBits() { method swapAdjacentBits (line 43) | public static int swapAdjacentBits(int num) { FILE: src/main/java/com/thealgorithms/bitmanipulation/TwosComplement.java class TwosComplement (line 18) | public final class TwosComplement { method TwosComplement (line 19) | private TwosComplement() { method twosComplement (line 34) | public static String twosComplement(String binary) { FILE: src/main/java/com/thealgorithms/bitmanipulation/Xs3Conversion.java class Xs3Conversion (line 20) | public final class Xs3Conversion { method Xs3Conversion (line 21) | private Xs3Conversion() { method xs3ToBinary (line 29) | public static int xs3ToBinary(int xs3) { method binaryToXs3 (line 47) | public static int binaryToXs3(int binary) { FILE: src/main/java/com/thealgorithms/ciphers/ADFGVXCipher.java class ADFGVXCipher (line 27) | public class ADFGVXCipher { method encrypt (line 58) | public String encrypt(String plaintext, String key) { method decrypt (line 80) | public String decrypt(String ciphertext, String key) { method columnarTransposition (line 99) | private String columnarTransposition(String text, String key) { method reverseColumnarTransposition (line 135) | private String reverseColumnarTransposition(String ciphertext, String ... FILE: src/main/java/com/thealgorithms/ciphers/AES.java class AES (line 10) | public final class AES { method AES (line 11) | private AES() { method scheduleCore (line 2384) | public static BigInteger scheduleCore(BigInteger t, int rconCounter) { method keyExpansion (line 2430) | public static BigInteger[] keyExpansion(BigInteger initialKey) { method splitBlockIntoCells (line 2485) | public static int[] splitBlockIntoCells(BigInteger block) { method mergeCellsIntoBlock (line 2510) | public static BigInteger mergeCellsIntoBlock(int[] cells) { method addRoundKey (line 2529) | public static BigInteger addRoundKey(BigInteger ciphertext, BigInteger... method subBytes (line 2539) | public static BigInteger subBytes(BigInteger ciphertext) { method subBytesDec (line 2555) | public static BigInteger subBytesDec(BigInteger ciphertext) { method shiftRows (line 2569) | public static BigInteger shiftRows(BigInteger ciphertext) { method shiftRowsDec (line 2604) | public static BigInteger shiftRowsDec(BigInteger ciphertext) { method mixColumns (line 2638) | public static BigInteger mixColumns(BigInteger ciphertext) { method mixColumnsDec (line 2662) | public static BigInteger mixColumnsDec(BigInteger ciphertext) { method encrypt (line 2689) | public static BigInteger encrypt(BigInteger plainText, BigInteger key) { method decrypt (line 2717) | public static BigInteger decrypt(BigInteger cipherText, BigInteger key) { method main (line 2739) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/ciphers/AESEncryption.java class AESEncryption (line 20) | public final class AESEncryption { method AESEncryption (line 21) | private AESEncryption() { method main (line 32) | public static void main(String[] args) throws Exception { method getSecretEncryptionKey (line 51) | public static SecretKey getSecretEncryptionKey() throws NoSuchAlgorith... method encryptText (line 67) | public static byte[] encryptText(String plainText, SecretKey secKey) t... method decryptText (line 79) | public static String decryptText(byte[] byteCipherText, SecretKey secK... method bytesToHex (line 95) | public static String bytesToHex(byte[] bytes) { FILE: src/main/java/com/thealgorithms/ciphers/AffineCipher.java class AffineCipher (line 21) | final class AffineCipher { method AffineCipher (line 22) | private AffineCipher() { method encryptMessage (line 35) | static String encryptMessage(char[] msg) { method decryptCipher (line 58) | static String decryptCipher(String cipher) { FILE: src/main/java/com/thealgorithms/ciphers/AtbashCipher.java class AtbashCipher (line 26) | public class AtbashCipher { method AtbashCipher (line 30) | public AtbashCipher() { method AtbashCipher (line 38) | public AtbashCipher(String str) { method getString (line 47) | public String getString() { method setString (line 56) | public void setString(String str) { method isCapital (line 66) | private boolean isCapital(char ch) { method isSmall (line 76) | private boolean isSmall(char ch) { method convert (line 87) | public String convert() { FILE: src/main/java/com/thealgorithms/ciphers/Autokey.java class Autokey (line 12) | public class Autokey { method encrypt (line 15) | public String encrypt(String plaintext, String keyword) { method decrypt (line 36) | public String decrypt(String ciphertext, String keyword) { FILE: src/main/java/com/thealgorithms/ciphers/BaconianCipher.java class BaconianCipher (line 14) | public class BaconianCipher { method encrypt (line 40) | public String encrypt(String plaintext) { method decrypt (line 57) | public String decrypt(String ciphertext) { FILE: src/main/java/com/thealgorithms/ciphers/Blowfish.java class Blowfish (line 11) | public class Blowfish { method hexToBin (line 1080) | private String hexToBin(String hex) { method binToHex (line 1104) | private String binToHex(String binary) { method xor (line 1121) | private String xor(String a, String b) { method addBin (line 1140) | private String addBin(String a, String b) { method f (line 1155) | private String f(String plainText) { method keyGenerate (line 1170) | private void keyGenerate(String key) { method round (line 1181) | private String round(int time, String plainText) { method encrypt (line 1205) | String encrypt(String plainText, String key) { method decrypt (line 1229) | String decrypt(String cipherText, String key) { FILE: src/main/java/com/thealgorithms/ciphers/Caesar.java class Caesar (line 11) | public class Caesar { method normalizeShift (line 12) | private static char normalizeShift(final int shift) { method encode (line 22) | public String encode(String message, int shift) { method decode (line 53) | public String decode(String encryptedMessage, int shift) { method isCapitalLatinLetter (line 77) | private static boolean isCapitalLatinLetter(char c) { method isSmallLatinLetter (line 84) | private static boolean isSmallLatinLetter(char c) { method bruteforce (line 91) | public String[] bruteforce(String encryptedMessage) { FILE: src/main/java/com/thealgorithms/ciphers/ColumnarTranspositionCipher.java class ColumnarTranspositionCipher (line 10) | public final class ColumnarTranspositionCipher { method ColumnarTranspositionCipher (line 11) | private ColumnarTranspositionCipher() { method encrypt (line 30) | public static String encrypt(final String word, final String keyword) { method encrypt (line 54) | public static String encrypt(String word, String keyword, String abece... method decrypt (line 76) | public static String decrypt() { method tableBuilder (line 93) | private static Object[][] tableBuilder(String word) { method numberOfRows (line 119) | private static int numberOfRows(String word) { method findElements (line 130) | private static Object[] findElements() { method sortTable (line 142) | private static Object[][] sortTable(Object[][] table) { method getColumn (line 161) | private static Object[] getColumn(Object[][] table, int rows, int colu... method switchColumns (line 169) | private static void switchColumns(Object[][] table, int firstColumnInd... method abecedariumBuilder (line 179) | private static void abecedariumBuilder() { FILE: src/main/java/com/thealgorithms/ciphers/DES.java class DES (line 8) | public class DES { method sanitize (line 13) | private void sanitize(String key) { method DES (line 20) | DES(String key) { method getKey (line 26) | public String getKey() { method setKey (line 30) | public void setKey(String key) { method getSubkeys (line 75) | private String[] getSubkeys(String originalKey) { method xOR (line 109) | private String xOR(String a, String b) { method createPaddedString (line 121) | private String createPaddedString(String s, int desiredLength, char pa... method pad (line 132) | private String pad(String s, int desiredLength) { method padLast (line 136) | private String padLast(String s, int desiredLength) { method feistel (line 140) | private String feistel(String messageBlock, String key) { method encryptBlock (line 166) | private String encryptBlock(String message, String[] keys) { method decryptBlock (line 192) | private String decryptBlock(String message, String[] keys) { method encrypt (line 204) | public String encrypt(String message) { method decrypt (line 231) | public String decrypt(String message) { FILE: src/main/java/com/thealgorithms/ciphers/DiffieHellman.java class DiffieHellman (line 5) | public final class DiffieHellman { method DiffieHellman (line 12) | public DiffieHellman(BigInteger base, BigInteger secret, BigInteger pr... method calculatePublicValue (line 23) | public BigInteger calculatePublicValue() { method calculateSharedSecret (line 29) | public BigInteger calculateSharedSecret(BigInteger otherPublicValue) { FILE: src/main/java/com/thealgorithms/ciphers/ECC.java class ECC (line 18) | public class ECC { method ECC (line 25) | public ECC(int bits) { method getCurve (line 29) | public EllipticCurve getCurve() { method setCurve (line 33) | public void setCurve(EllipticCurve curve) { method getPrivateKey (line 38) | public BigInteger getPrivateKey() { method setPrivateKey (line 42) | public void setPrivateKey(BigInteger privateKey) { method encrypt (line 53) | public ECPoint[] encrypt(String message) { method decrypt (line 74) | public String decrypt(ECPoint[] encryptedMessage) { method generateKeys (line 91) | public final void generateKeys(int bits) { class EllipticCurve (line 106) | public static class EllipticCurve { method EllipticCurve (line 113) | public EllipticCurve(BigInteger a, BigInteger b, BigInteger p, ECPoi... method EllipticCurve (line 121) | public EllipticCurve(int bits) { method getBasePoint (line 129) | public ECPoint getBasePoint() { method getP (line 133) | public BigInteger getP() { method getA (line 137) | public BigInteger getA() { method getB (line 141) | public BigInteger getB() { method getFieldSize (line 145) | public int getFieldSize() { method encodeMessage (line 149) | public ECPoint encodeMessage(BigInteger message) { method decodeMessage (line 154) | public BigInteger decodeMessage(ECPoint point) { class ECPoint (line 162) | public static class ECPoint { method ECPoint (line 166) | public ECPoint(BigInteger x, BigInteger y) { method getX (line 171) | public BigInteger getX() { method getY (line 175) | public BigInteger getY() { method toString (line 179) | @Override method add (line 187) | public ECPoint add(ECPoint other, BigInteger p, BigInteger a) { method subtract (line 213) | public ECPoint subtract(ECPoint other, BigInteger p, BigInteger a) { method multiply (line 221) | public ECPoint multiply(BigInteger k, BigInteger p, BigInteger a) { FILE: src/main/java/com/thealgorithms/ciphers/ElGamalCipher.java class ElGamalCipher (line 29) | public final class ElGamalCipher { method ElGamalCipher (line 35) | private ElGamalCipher() { method generateKeys (line 65) | public static KeyPair generateKeys(int bitLength) { method encrypt (line 108) | public static CipherText encrypt(BigInteger message, BigInteger p, Big... method decrypt (line 142) | public static BigInteger decrypt(CipherText cipher, BigInteger x, BigI... method isValidGenerator (line 164) | private static boolean isValidGenerator(BigInteger g, BigInteger p, Bi... FILE: src/main/java/com/thealgorithms/ciphers/HillCipher.java class HillCipher (line 3) | public class HillCipher { method encrypt (line 6) | public String encrypt(String message, int[][] keyMatrix) { method decrypt (line 39) | public String decrypt(String message, int[][] inverseKeyMatrix) { method validateDeterminant (line 72) | private void validateDeterminant(int[][] keyMatrix, int n) { method determinant (line 80) | private int determinant(int[][] matrix, int n) { FILE: src/main/java/com/thealgorithms/ciphers/MonoAlphabetic.java class MonoAlphabetic (line 3) | public final class MonoAlphabetic { method MonoAlphabetic (line 5) | private MonoAlphabetic() { method encrypt (line 10) | public static String encrypt(String data, String key) { method decrypt (line 25) | public static String decrypt(String data, String key) { method charToPos (line 40) | private static int charToPos(char c) { method posToChar (line 45) | private static char posToChar(int pos) { FILE: src/main/java/com/thealgorithms/ciphers/OneTimePadCipher.java class OneTimePadCipher (line 19) | public final class OneTimePadCipher { method OneTimePadCipher (line 23) | private OneTimePadCipher() { method generateKey (line 34) | public static byte[] generateKey(int length) { method encrypt (line 53) | public static byte[] encrypt(byte[] plaintext, byte[] key) { method decrypt (line 69) | public static byte[] decrypt(byte[] ciphertext, byte[] key) { method validateInputs (line 74) | private static void validateInputs(byte[] input, byte[] key) { method xor (line 82) | private static byte[] xor(byte[] data, byte[] key) { FILE: src/main/java/com/thealgorithms/ciphers/PermutationCipher.java class PermutationCipher (line 17) | public class PermutationCipher { method encrypt (line 29) | public String encrypt(String plaintext, int[] key) { method decrypt (line 61) | public String decrypt(String ciphertext, int[] key) { method validateKey (line 89) | private void validateKey(int[] key) { method padText (line 112) | private String padText(String text, int blockSize) { method permuteBlock (line 133) | private String permuteBlock(String block, int[] key) { method createInverseKey (line 156) | private int[] createInverseKey(int[] key) { method removePadding (line 173) | private String removePadding(String text) { method getPaddingChar (line 191) | public char getPaddingChar() { FILE: src/main/java/com/thealgorithms/ciphers/PlayfairCipher.java class PlayfairCipher (line 3) | public class PlayfairCipher { method PlayfairCipher (line 8) | public PlayfairCipher(String key) { method encrypt (line 13) | public String encrypt(String plaintext) { method decrypt (line 39) | public String decrypt(String ciphertext) { method generateMatrix (line 64) | private void generateMatrix() { method removeDuplicateChars (line 76) | private String removeDuplicateChars(String str) { method prepareText (line 86) | private String prepareText(String text) { method findPosition (line 105) | private int[] findPosition(char c) { method printMatrix (line 119) | public void printMatrix() { FILE: src/main/java/com/thealgorithms/ciphers/Polybius.java class Polybius (line 16) | public final class Polybius { method Polybius (line 17) | private Polybius() { method findLocationByCharacter (line 29) | private static String findLocationByCharacter(final char character) { method encrypt (line 42) | public static String encrypt(final String plaintext) { method decrypt (line 52) | public static String decrypt(final String ciphertext) { FILE: src/main/java/com/thealgorithms/ciphers/ProductCipher.java class ProductCipher (line 5) | final class ProductCipher { method ProductCipher (line 6) | private ProductCipher() { method main (line 9) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/ciphers/RSA.java class RSA (line 29) | public class RSA { method RSA (line 40) | public RSA(int bits) { method encrypt (line 51) | public synchronized String encrypt(String message) { method encrypt (line 64) | public synchronized BigInteger encrypt(BigInteger message) { method decrypt (line 75) | public synchronized String decrypt(String encryptedMessage) { method decrypt (line 88) | public synchronized BigInteger decrypt(BigInteger encryptedMessage) { method generateKeys (line 104) | public final synchronized void generateKeys(int bits) { FILE: src/main/java/com/thealgorithms/ciphers/RailFenceCipher.java class RailFenceCipher (line 12) | public class RailFenceCipher { method encrypt (line 15) | public String encrypt(String str, int rails) { method decrypt (line 73) | public String decrypt(String str, int rails) { FILE: src/main/java/com/thealgorithms/ciphers/SimpleSubCipher.java class SimpleSubCipher (line 13) | public class SimpleSubCipher { method encode (line 22) | public String encode(String message, String cipherSmall) { method decode (line 59) | public String decode(String encryptedMessage, String cipherSmall) { FILE: src/main/java/com/thealgorithms/ciphers/Vigenere.java class Vigenere (line 29) | public class Vigenere { method encrypt (line 46) | public String encrypt(final String message, final String key) { method decrypt (line 84) | public String decrypt(final String message, final String key) { FILE: src/main/java/com/thealgorithms/ciphers/XORCipher.java class XORCipher (line 32) | public final class XORCipher { method XORCipher (line 37) | private XORCipher() { method xor (line 48) | public static byte[] xor(final byte[] inputBytes, final byte[] keyByte... method encrypt (line 65) | public static String encrypt(final String plainText, final String key) { method decrypt (line 85) | public static String decrypt(final String cipherText, final String key) { FILE: src/main/java/com/thealgorithms/ciphers/a5/A5Cipher.java class A5Cipher (line 17) | public class A5Cipher { method A5Cipher (line 28) | public A5Cipher(BitSet sessionKey, BitSet frameCounter) { method encrypt (line 42) | public BitSet encrypt(BitSet plainTextBits) { method resetCounter (line 60) | public void resetCounter() { FILE: src/main/java/com/thealgorithms/ciphers/a5/A5KeyStreamGenerator.java class A5KeyStreamGenerator (line 18) | public class A5KeyStreamGenerator extends CompositeLFSR { method initialize (line 38) | @Override method reInitialize (line 58) | public void reInitialize() { method getNextKeyStream (line 73) | public BitSet getNextKeyStream() { method reInitializeRegisters (line 96) | private void reInitializeRegisters() { method incrementFrameCounter (line 109) | private void incrementFrameCounter() { method getFrameCounter (line 118) | public BitSet getFrameCounter() { FILE: src/main/java/com/thealgorithms/ciphers/a5/BaseLFSR.java type BaseLFSR (line 5) | public interface BaseLFSR { method initialize (line 6) | void initialize(BitSet sessionKey, BitSet frameCounter); method clock (line 7) | boolean clock(); FILE: src/main/java/com/thealgorithms/ciphers/a5/CompositeLFSR.java class CompositeLFSR (line 19) | public abstract class CompositeLFSR implements BaseLFSR { method clock (line 36) | @Override method getMajorityBit (line 61) | private boolean getMajorityBit() { FILE: src/main/java/com/thealgorithms/ciphers/a5/LFSR.java class LFSR (line 5) | public class LFSR implements BaseLFSR { method LFSR (line 12) | public LFSR(int length, int clockBitIndex, int[] tappingBitsIndices) { method initialize (line 19) | @Override method clock (line 26) | private void clock(BitSet key, int keyLength) { method clock (line 35) | @Override method getClockBit (line 40) | public boolean getClockBit() { method get (line 44) | public boolean get(int bitIndex) { method getLastBit (line 48) | public boolean getLastBit() { method xorTappingBits (line 52) | private boolean xorTappingBits() { method pushBit (line 60) | private boolean pushBit(boolean bit) { method rightShift (line 66) | private boolean rightShift() { method toString (line 75) | @Override FILE: src/main/java/com/thealgorithms/ciphers/a5/Utils.java class Utils (line 10) | public final class Utils { method Utils (line 11) | private Utils() { method increment (line 14) | public static boolean increment(BitSet bits, int size) { FILE: src/main/java/com/thealgorithms/compression/ArithmeticCoding.java class ArithmeticCoding (line 42) | public final class ArithmeticCoding { method ArithmeticCoding (line 44) | private ArithmeticCoding() { method compress (line 54) | public static BigDecimal compress(String uncompressed) { method decompress (line 83) | public static String decompress(BigDecimal compressed, int length, Map... method calculateProbabilities (line 128) | public static Map calculateProbabilities(String tex... FILE: src/main/java/com/thealgorithms/compression/BurrowsWheelerTransform.java class BurrowsWheelerTransform (line 52) | public final class BurrowsWheelerTransform { method BurrowsWheelerTransform (line 54) | private BurrowsWheelerTransform() { class BWTResult (line 65) | public static class BWTResult { method BWTResult (line 78) | public BWTResult(String transformed, int originalIndex) { method equals (line 83) | @Override method hashCode (line 95) | @Override method toString (line 100) | @Override method transform (line 124) | public static BWTResult transform(String text) { method inverseTransform (line 171) | public static String inverseTransform(String bwtString, int originalIn... FILE: src/main/java/com/thealgorithms/compression/HuffmanCoding.java class HuffmanCoding (line 28) | public class HuffmanCoding { class Node (line 37) | private static class Node implements Comparable { method Node (line 49) | Node(char ch, int freq) { method Node (line 64) | Node(int freq, Node left, Node right) { method isLeaf (line 76) | boolean isLeaf() { method compareTo (line 88) | @Override method HuffmanCoding (line 101) | public HuffmanCoding(String text) { method buildTree (line 125) | private void buildTree(String text) { method generateCodes (line 153) | private void generateCodes(Node node, String code, Map getHuffmanCodes() { FILE: src/main/java/com/thealgorithms/compression/LZ77.java class LZ77 (line 29) | public final class LZ77 { method LZ77 (line 34) | private LZ77() { method compress (line 54) | public static List compress(String text, int windowSize, int lo... method compress (line 132) | public static List compress(String text) { method decompress (line 142) | public static String decompress(List compressedData) { FILE: src/main/java/com/thealgorithms/compression/LZ78.java class LZ78 (line 32) | public final class LZ78 { method LZ78 (line 42) | private LZ78() { class TrieNode (line 57) | private static final class TrieNode { method compress (line 68) | public static List compress(String text) { method decompress (line 113) | public static String decompress(List compressedData) { FILE: src/main/java/com/thealgorithms/compression/LZW.java class LZW (line 42) | public final class LZW { method LZW (line 47) | private LZW() { method compress (line 57) | public static List compress(String uncompressed) { method decompress (line 99) | public static String decompress(List compressed) { FILE: src/main/java/com/thealgorithms/compression/MoveToFront.java class MoveToFront (line 64) | public final class MoveToFront { method MoveToFront (line 66) | private MoveToFront() { method transform (line 91) | public static List transform(String text, String initialAlpha... method inverseTransform (line 139) | public static String inverseTransform(Collection indices, Str... FILE: src/main/java/com/thealgorithms/compression/RunLengthEncoding.java class RunLengthEncoding (line 26) | public final class RunLengthEncoding { method RunLengthEncoding (line 31) | private RunLengthEncoding() { method compress (line 40) | public static String compress(String text) { method decompress (line 67) | public static String decompress(String compressedText) { FILE: src/main/java/com/thealgorithms/compression/ShannonFano.java class ShannonFano (line 39) | public final class ShannonFano { method ShannonFano (line 44) | private ShannonFano() { class Symbol (line 51) | private static class Symbol implements Comparable { method Symbol (line 56) | Symbol(char character, int frequency) { method compareTo (line 61) | @Override method generateCodes (line 73) | public static Map generateCodes(String text) { method buildCodeTree (line 109) | private static void buildCodeTree(List symbols, int start, int... method findSplitIndex (line 135) | private static int findSplitIndex(List symbols, int start, int... FILE: src/main/java/com/thealgorithms/conversions/AffineConverter.java class AffineConverter (line 10) | public final class AffineConverter { method AffineConverter (line 21) | public AffineConverter(final double inSlope, final double inIntercept) { method convert (line 36) | public double convert(final double inValue) { method invert (line 47) | public AffineConverter invert() { method compose (line 59) | public AffineConverter compose(final AffineConverter other) { FILE: src/main/java/com/thealgorithms/conversions/AnyBaseToAnyBase.java class AnyBaseToAnyBase (line 23) | public final class AnyBaseToAnyBase { method AnyBaseToAnyBase (line 24) | private AnyBaseToAnyBase() { method main (line 34) | public static void main(String[] args) { method validForBase (line 72) | public static boolean validForBase(String n, int base) { method base2base (line 139) | public static String base2base(String n, int b1, int b2) { FILE: src/main/java/com/thealgorithms/conversions/AnyBaseToDecimal.java class AnyBaseToDecimal (line 6) | public final class AnyBaseToDecimal { method AnyBaseToDecimal (line 10) | private AnyBaseToDecimal() { method convertToDecimal (line 21) | public static int convertToDecimal(String input, int radix) { method valOfChar (line 43) | private static int valOfChar(char character) { FILE: src/main/java/com/thealgorithms/conversions/AnytoAny.java class AnytoAny (line 9) | public final class AnytoAny { method AnytoAny (line 10) | private AnytoAny() { method convertBase (line 22) | public static int convertBase(int sourceNumber, int sourceBase, int de... method toDecimal (line 38) | private static int toDecimal(int number, int base) { method fromDecimal (line 57) | private static int fromDecimal(int decimal, int base) { FILE: src/main/java/com/thealgorithms/conversions/Base64.java class Base64 (line 21) | public final class Base64 { method Base64 (line 27) | private Base64() { method encode (line 37) | public static String encode(byte[] input) { method encode (line 91) | public static String encode(String input) { method decode (line 106) | public static byte[] decode(String input) { method decodeToString (line 165) | public static String decodeToString(String input) { method getBase64Value (line 181) | private static int getBase64Value(char c) { FILE: src/main/java/com/thealgorithms/conversions/BinaryToDecimal.java class BinaryToDecimal (line 6) | final class BinaryToDecimal { method BinaryToDecimal (line 9) | private BinaryToDecimal() { method binaryToDecimal (line 19) | public static long binaryToDecimal(long binaryNumber) { method binaryStringToDecimal (line 41) | public static long binaryStringToDecimal(String binary) { FILE: src/main/java/com/thealgorithms/conversions/BinaryToHexadecimal.java class BinaryToHexadecimal (line 11) | public final class BinaryToHexadecimal { method BinaryToHexadecimal (line 18) | private BinaryToHexadecimal() { method binToHex (line 28) | public static String binToHex(int binary) { method initializeHexMap (line 53) | private static Map initializeHexMap() { FILE: src/main/java/com/thealgorithms/conversions/BinaryToOctal.java class BinaryToOctal (line 3) | public final class BinaryToOctal { method BinaryToOctal (line 8) | private BinaryToOctal() { method convertBinaryToOctal (line 18) | public static String convertBinaryToOctal(int binary) { FILE: src/main/java/com/thealgorithms/conversions/CoordinateConverter.java class CoordinateConverter (line 14) | public final class CoordinateConverter { method CoordinateConverter (line 16) | private CoordinateConverter() { method cartesianToPolar (line 28) | public static double[] cartesianToPolar(double x, double y) { method polarToCartesian (line 45) | public static double[] polarToCartesian(double r, double thetaDegrees) { FILE: src/main/java/com/thealgorithms/conversions/DecimalToAnyBase.java class DecimalToAnyBase (line 12) | public final class DecimalToAnyBase { method DecimalToAnyBase (line 19) | private DecimalToAnyBase() { method convertToAnyBase (line 31) | public static String convertToAnyBase(int decimal, int base) { method convertToChar (line 62) | private static char convertToChar(int value) { FILE: src/main/java/com/thealgorithms/conversions/DecimalToBinary.java class DecimalToBinary (line 6) | final class DecimalToBinary { method DecimalToBinary (line 10) | private DecimalToBinary() { method convertUsingConventionalAlgorithm (line 18) | public static int convertUsingConventionalAlgorithm(int decimalNumber) { method convertUsingBitwiseAlgorithm (line 37) | public static int convertUsingBitwiseAlgorithm(int decimalNumber) { FILE: src/main/java/com/thealgorithms/conversions/DecimalToHexadecimal.java class DecimalToHexadecimal (line 6) | final class DecimalToHexadecimal { method DecimalToHexadecimal (line 12) | private DecimalToHexadecimal() { method decToHex (line 20) | public static String decToHex(int decimal) { method removeLeadingZeros (line 30) | private static String removeLeadingZeros(String str) { FILE: src/main/java/com/thealgorithms/conversions/DecimalToOctal.java class DecimalToOctal (line 6) | public final class DecimalToOctal { method DecimalToOctal (line 11) | private DecimalToOctal() { method convertToOctal (line 21) | public static int convertToOctal(int decimal) { FILE: src/main/java/com/thealgorithms/conversions/EndianConverter.java class EndianConverter (line 24) | public final class EndianConverter { method EndianConverter (line 25) | private EndianConverter() { method bigToLittleEndian (line 34) | public static int bigToLittleEndian(int value) { method littleToBigEndian (line 44) | public static int littleToBigEndian(int value) { FILE: src/main/java/com/thealgorithms/conversions/HexToOct.java class HexToOct (line 8) | public final class HexToOct { method HexToOct (line 9) | private HexToOct() { method hexToDecimal (line 18) | public static int hexToDecimal(String hex) { method decimalToOctal (line 38) | public static int decimalToOctal(int decimal) { method hexToOctal (line 58) | public static int hexToOctal(String hex) { FILE: src/main/java/com/thealgorithms/conversions/HexaDecimalToBinary.java class HexaDecimalToBinary (line 23) | public class HexaDecimalToBinary { method convert (line 40) | public String convert(String numHex) { method completeDigits (line 53) | public String completeDigits(String binNum) { FILE: src/main/java/com/thealgorithms/conversions/HexaDecimalToDecimal.java class HexaDecimalToDecimal (line 18) | public final class HexaDecimalToDecimal { method HexaDecimalToDecimal (line 19) | private HexaDecimalToDecimal() { method getHexaToDec (line 30) | public static int getHexaToDec(String hex) { FILE: src/main/java/com/thealgorithms/conversions/IPConverter.java class IPConverter (line 13) | public final class IPConverter { method IPConverter (line 14) | private IPConverter() { method ipToBinary (line 22) | public static String ipToBinary(String ip) { method octetToBinary (line 35) | private static String octetToBinary(int octet) { method binaryToIP (line 51) | public static String binaryToIP(String binary) { FILE: src/main/java/com/thealgorithms/conversions/IPv6Converter.java class IPv6Converter (line 16) | public final class IPv6Converter { method IPv6Converter (line 17) | private IPv6Converter() { method ipv4ToIpv6 (line 29) | public static String ipv4ToIpv6(String ipv4Address) throws UnknownHost... method ipv6ToIpv4 (line 62) | public static String ipv6ToIpv4(String ipv6Address) throws UnknownHost... method isValidIpv6MappedIpv4 (line 83) | private static boolean isValidIpv6MappedIpv4(byte[] ipv6Bytes) { FILE: src/main/java/com/thealgorithms/conversions/IntegerToEnglish.java class IntegerToEnglish (line 25) | public final class IntegerToEnglish { method IntegerToEnglish (line 33) | private IntegerToEnglish() { method convertToWords (line 42) | private static String convertToWords(int number) { method integerToEnglishWords (line 78) | public static String integerToEnglishWords(int number) { FILE: src/main/java/com/thealgorithms/conversions/IntegerToRoman.java class IntegerToRoman (line 27) | public final class IntegerToRoman { method IntegerToRoman (line 35) | private IntegerToRoman() { method integerToRoman (line 54) | public static String integerToRoman(int num) { FILE: src/main/java/com/thealgorithms/conversions/MorseCodeConverter.java class MorseCodeConverter (line 18) | public final class MorseCodeConverter { method MorseCodeConverter (line 19) | private MorseCodeConverter() { method textToMorse (line 64) | public static String textToMorse(String text) { method morseToText (line 85) | public static String morseToText(String morse) { FILE: src/main/java/com/thealgorithms/conversions/NumberToWords.java class NumberToWords (line 12) | public final class NumberToWords { method NumberToWords (line 14) | private NumberToWords() { method convert (line 27) | public static String convert(BigDecimal number) { method convertWholeNumberToWords (line 59) | private static String convertWholeNumberToWords(BigDecimal number) { method convertChunk (line 87) | private static String convertChunk(int number) { FILE: src/main/java/com/thealgorithms/conversions/OctalToBinary.java class OctalToBinary (line 25) | public final class OctalToBinary { method OctalToBinary (line 26) | private OctalToBinary() { method convertOctalToBinary (line 38) | public static long convertOctalToBinary(int octalNumber) { method convertOctalDigitToBinary (line 68) | public static long convertOctalDigitToBinary(int octalDigit) { FILE: src/main/java/com/thealgorithms/conversions/OctalToDecimal.java class OctalToDecimal (line 7) | public final class OctalToDecimal { method OctalToDecimal (line 10) | private OctalToDecimal() { method convertOctalToDecimal (line 22) | public static int convertOctalToDecimal(String inputOctal) { FILE: src/main/java/com/thealgorithms/conversions/OctalToHexadecimal.java class OctalToHexadecimal (line 8) | public final class OctalToHexadecimal { method OctalToHexadecimal (line 13) | private OctalToHexadecimal() { method octalToDecimal (line 23) | public static int octalToDecimal(String octalNumber) { method decimalToHexadecimal (line 47) | public static String decimalToHexadecimal(int decimalNumber) { FILE: src/main/java/com/thealgorithms/conversions/PhoneticAlphabetConverter.java class PhoneticAlphabetConverter (line 16) | public final class PhoneticAlphabetConverter { method PhoneticAlphabetConverter (line 17) | private PhoneticAlphabetConverter() { method textToPhonetic (line 74) | public static String textToPhonetic(String text) { FILE: src/main/java/com/thealgorithms/conversions/RgbHsvConversion.java class RgbHsvConversion (line 16) | public final class RgbHsvConversion { method RgbHsvConversion (line 17) | private RgbHsvConversion() { method main (line 20) | public static void main(String[] args) { method hsvToRgb (line 58) | public static int[] hsvToRgb(double hue, double saturation, double val... method rgbToHsv (line 87) | public static double[] rgbToHsv(int red, int green, int blue) { method approximatelyEqualHsv (line 123) | private static boolean approximatelyEqualHsv(double[] hsv1, double[] h... method getRgbBySection (line 131) | private static int[] getRgbBySection(double hueSection, double chroma,... method convertToInt (line 165) | private static int convertToInt(double input) { FILE: src/main/java/com/thealgorithms/conversions/RomanToInteger.java class RomanToInteger (line 26) | public final class RomanToInteger { method RomanToInteger (line 40) | private RomanToInteger() { method romanSymbolToInt (line 50) | private static int romanSymbolToInt(final char symbol) { method romanToInt (line 71) | public static int romanToInt(String roman) { FILE: src/main/java/com/thealgorithms/conversions/TemperatureConverter.java class TemperatureConverter (line 18) | public final class TemperatureConverter { method TemperatureConverter (line 20) | private TemperatureConverter() { method celsiusToFahrenheit (line 23) | public static double celsiusToFahrenheit(double celsius) { method celsiusToKelvin (line 27) | public static double celsiusToKelvin(double celsius) { method fahrenheitToCelsius (line 31) | public static double fahrenheitToCelsius(double fahrenheit) { method fahrenheitToKelvin (line 35) | public static double fahrenheitToKelvin(double fahrenheit) { method kelvinToCelsius (line 39) | public static double kelvinToCelsius(double kelvin) { method kelvinToFahrenheit (line 43) | public static double kelvinToFahrenheit(double kelvin) { FILE: src/main/java/com/thealgorithms/conversions/TimeConverter.java class TimeConverter (line 27) | public final class TimeConverter { method TimeConverter (line 29) | private TimeConverter() { type TimeUnit (line 36) | private enum TimeUnit { method TimeUnit (line 47) | TimeUnit(double seconds) { method toSeconds (line 51) | public double toSeconds(double value) { method fromSeconds (line 55) | public double fromSeconds(double secondsValue) { method convertTime (line 73) | public static double convertTime(double timeValue, String unitFrom, St... method resolveUnit (line 87) | private static TimeUnit resolveUnit(String unit) { FILE: src/main/java/com/thealgorithms/conversions/TurkishToLatinConversion.java class TurkishToLatinConversion (line 8) | public final class TurkishToLatinConversion { method TurkishToLatinConversion (line 9) | private TurkishToLatinConversion() { method convertTurkishToLatin (line 22) | public static String convertTurkishToLatin(String param) { FILE: src/main/java/com/thealgorithms/conversions/UnitConversions.java class UnitConversions (line 34) | public final class UnitConversions { method UnitConversions (line 35) | private UnitConversions() { FILE: src/main/java/com/thealgorithms/conversions/UnitsConverter.java class UnitsConverter (line 47) | public final class UnitsConverter { method putIfNeeded (line 51) | private static void putIfNeeded(Map, AffineConver... method addInversions (line 58) | private static Map, AffineConverter> addInversion... method addCompositions (line 69) | private static Map, AffineConverter> addCompositi... method addAll (line 85) | private static Map, AffineConverter> addAll(final... method computeAllConversions (line 90) | private static Map, AffineConverter> computeAllCo... method extractUnits (line 100) | private static Set extractUnits(final Map... method UnitsConverter (line 116) | public UnitsConverter(final Map, AffineConverter>... method convert (line 131) | public double convert(final String inputUnit, final String outputUnit,... method availableUnits (line 144) | public Set availableUnits() { FILE: src/main/java/com/thealgorithms/conversions/WordsToNumber.java class WordsToNumber (line 19) | public final class WordsToNumber { method WordsToNumber (line 21) | private WordsToNumber() { type NumberWord (line 24) | private enum NumberWord { method NumberWord (line 57) | NumberWord(String word, int value) { method getValue (line 62) | public static Integer getValue(String word) { type PowerOfTen (line 72) | private enum PowerOfTen { method PowerOfTen (line 81) | PowerOfTen(String word, BigDecimal value) { method getValue (line 86) | public static BigDecimal getValue(String word) { method convert (line 96) | public static String convert(String numberInWords) { method convertToBigDecimal (line 107) | public static BigDecimal convertToBigDecimal(String numberInWords) { method preprocessWords (line 112) | private static ArrayDeque preprocessWords(String numberInWords) { method handleConjunction (line 127) | private static void handleConjunction(boolean prevNumWasHundred, boole... method handleHundred (line 147) | private static BigDecimal handleHundred(BigDecimal currentChunk, Strin... method handlePowerOfTen (line 158) | private static void handlePowerOfTen(List chunks, BigDecim... method handleNumber (line 171) | private static BigDecimal handleNumber(Collection chunks, ... method handlePoint (line 184) | private static void handlePoint(Collection chunks, BigDeci... method handleNegative (line 194) | private static void handleNegative(boolean isNegative) { method convertWordQueueToBigDecimal (line 201) | private static BigDecimal convertWordQueueToBigDecimal(ArrayDeque wordDeque) { method combineChunks (line 299) | private static BigDecimal combineChunks(List chunks) { class WordsToNumberException (line 308) | class WordsToNumberException extends RuntimeException { type ErrorType (line 312) | enum ErrorType { method ErrorType (line 324) | ErrorType(String message) { method formatMessage (line 328) | public String formatMessage(String details) { method WordsToNumberException (line 335) | WordsToNumberException(ErrorType errorType, String details) { method getErrorType (line 340) | public ErrorType getErrorType() { FILE: src/main/java/com/thealgorithms/datastructures/Node.java class Node (line 6) | public class Node { method Node (line 11) | public Node(final T value) { method Node (line 16) | public Node(final T value, final List> children) { method getValue (line 21) | public T getValue() { method addChild (line 25) | public void addChild(Node child) { method getChildren (line 29) | public List> getChildren() { FILE: src/main/java/com/thealgorithms/datastructures/bags/Bag.java class Bag (line 15) | public class Bag implements Iterable { class Node (line 21) | private static final class Node { method Bag (line 30) | public Bag() { method isEmpty (line 40) | public boolean isEmpty() { method size (line 49) | public int size() { method add (line 61) | public void add(E element) { method contains (line 77) | public boolean contains(E element) { method iterator (line 93) | @Override class ListIterator (line 99) | private static class ListIterator implements Iterator { method ListIterator (line 108) | ListIterator(Node firstElement) { method hasNext (line 117) | @Override method next (line 128) | @Override FILE: src/main/java/com/thealgorithms/datastructures/bloomfilter/BloomFilter.java class BloomFilter (line 18) | @SuppressWarnings("rawtypes") method BloomFilter (line 35) | @SuppressWarnings("unchecked") method initializeHashFunctions (line 50) | private void initializeHashFunctions() { method insert (line 66) | public void insert(T key) { method contains (line 87) | public boolean contains(T key) { class Hash (line 106) | private static class Hash { method Hash (line 115) | Hash(int index) { method compute (line 129) | public int compute(T key) { method asciiString (line 143) | private int asciiString(String word) { method contentHash (line 154) | private int contentHash(Object key) { FILE: src/main/java/com/thealgorithms/datastructures/buffers/CircularBuffer.java class CircularBuffer (line 13) | @SuppressWarnings("unchecked") method CircularBuffer (line 26) | public CircularBuffer(int size) { method isEmpty (line 42) | public boolean isEmpty() { method isFull (line 52) | public boolean isFull() { method get (line 62) | public Item get() { method put (line 80) | public boolean put(Item item) { class CircularPointer (line 106) | private static class CircularPointer { method CircularPointer (line 116) | CircularPointer(int pointer, int max) { method getAndIncrement (line 127) | public int getAndIncrement() { FILE: src/main/java/com/thealgorithms/datastructures/caches/FIFOCache.java class FIFOCache (line 36) | public final class FIFOCache { class CacheEntry (line 53) | private static class CacheEntry { method CacheEntry (line 65) | CacheEntry(V value, long ttlMillis) { method isExpired (line 79) | boolean isExpired() { method FIFOCache (line 92) | private FIFOCache(Builder builder) { method get (line 113) | public V get(K key) { method put (line 147) | public void put(K key, V value) { method put (line 164) | public void put(K key, V value, long ttlMillis) { method evictExpired (line 207) | private int evictExpired() { method removeKey (line 229) | public V removeKey(K key) { method notifyEviction (line 254) | private void notifyEviction(K key, V value) { method getHits (line 269) | public long getHits() { method getMisses (line 283) | public long getMisses() { method size (line 297) | public int size() { method clear (line 323) | public void clear() { method getAllKeys (line 348) | public Set getAllKeys() { method getEvictionStrategy (line 370) | public EvictionStrategy getEvictionStrategy() { method toString (line 383) | @Override type EvictionStrategy (line 409) | public interface EvictionStrategy { method onAccess (line 416) | int onAccess(FIFOCache cache); class ImmediateEvictionStrategy (line 425) | public static class ImmediateEvictionStrategy implements Evictio... method onAccess (line 426) | @Override class PeriodicEvictionStrategy (line 441) | public static class PeriodicEvictionStrategy implements Eviction... method PeriodicEvictionStrategy (line 451) | public PeriodicEvictionStrategy(int interval) { method onAccess (line 458) | @Override class Builder (line 477) | public static class Builder { method Builder (line 488) | public Builder(int capacity) { method defaultTTL (line 502) | public Builder defaultTTL(long ttlMillis) { method evictionListener (line 517) | public Builder evictionListener(BiConsumer listener) { method build (line 530) | public FIFOCache build() { method evictionStrategy (line 541) | public Builder evictionStrategy(EvictionStrategy strateg... FILE: src/main/java/com/thealgorithms/datastructures/caches/LFUCache.java class LFUCache (line 26) | public class LFUCache { class Node (line 33) | private class Node { method Node (line 47) | Node(K key, V value, int frequency) { method LFUCache (line 63) | public LFUCache() { method LFUCache (line 73) | public LFUCache(int capacity) { method get (line 89) | public V get(K key) { method put (line 108) | public void put(K key, V value) { method addNodeWithUpdatedFrequency (line 132) | private void addNodeWithUpdatedFrequency(Node node) { method removeNode (line 172) | private void removeNode(Node node) { FILE: src/main/java/com/thealgorithms/datastructures/caches/LIFOCache.java class LIFOCache (line 39) | public final class LIFOCache { class CacheEntry (line 56) | private static class CacheEntry { method CacheEntry (line 68) | CacheEntry(V value, long ttlMillis) { method isExpired (line 82) | boolean isExpired() { method LIFOCache (line 96) | private LIFOCache(Builder builder) { method get (line 118) | public V get(K key) { method put (line 153) | public void put(K key, V value) { method put (line 170) | public void put(K key, V value, long ttlMillis) { method evictExpired (line 212) | private int evictExpired() { method removeKey (line 236) | public V removeKey(K key) { method notifyEviction (line 267) | private void notifyEviction(K key, V value) { method getHits (line 282) | public long getHits() { method getMisses (line 296) | public long getMisses() { method size (line 310) | public int size() { method clear (line 336) | public void clear() { method getAllKeys (line 362) | public Set getAllKeys() { method getEvictionStrategy (line 384) | public EvictionStrategy getEvictionStrategy() { method toString (line 397) | @Override type EvictionStrategy (line 423) | public interface EvictionStrategy { method onAccess (line 430) | int onAccess(LIFOCache cache); class ImmediateEvictionStrategy (line 439) | public static class ImmediateEvictionStrategy implements Evictio... method onAccess (line 440) | @Override class PeriodicEvictionStrategy (line 455) | public static class PeriodicEvictionStrategy implements Eviction... method PeriodicEvictionStrategy (line 465) | public PeriodicEvictionStrategy(int interval) { method onAccess (line 472) | @Override class Builder (line 491) | public static class Builder { method Builder (line 502) | public Builder(int capacity) { method defaultTTL (line 516) | public Builder defaultTTL(long ttlMillis) { method evictionListener (line 531) | public Builder evictionListener(BiConsumer listener) { method build (line 544) | public LIFOCache build() { method evictionStrategy (line 555) | public Builder evictionStrategy(EvictionStrategy strateg... FILE: src/main/java/com/thealgorithms/datastructures/caches/LRUCache.java class LRUCache (line 42) | public class LRUCache { method LRUCache (line 50) | public LRUCache() { method LRUCache (line 54) | public LRUCache(int cap) { method setCapacity (line 63) | private void setCapacity(int newCapacity) { method evict (line 77) | private Entry evict() { method checkCapacity (line 93) | private void checkCapacity(int capacity) { method get (line 107) | public V get(K key) { method moveNodeToLast (line 121) | private void moveNodeToLast(Entry entry) { method put (line 148) | public void put(K key, V value) { method addNewEntry (line 174) | private void addNewEntry(Entry newEntry) { class Entry (line 186) | static final class Entry { method Entry (line 193) | Entry() { method Entry (line 196) | Entry(Entry preEntry, Entry nextEntry, I key, J value) { method getPreEntry (line 203) | public Entry getPreEntry() { method setPreEntry (line 207) | public void setPreEntry(Entry preEntry) { method getNextEntry (line 211) | public Entry getNextEntry() { method setNextEntry (line 215) | public void setNextEntry(Entry nextEntry) { method getKey (line 219) | public I getKey() { method setKey (line 223) | public void setKey(I key) { method getValue (line 227) | public J getValue() { method setValue (line 231) | public void setValue(J value) { FILE: src/main/java/com/thealgorithms/datastructures/caches/MRUCache.java class MRUCache (line 19) | public class MRUCache { method MRUCache (line 30) | public MRUCache() { method MRUCache (line 39) | public MRUCache(int cap) { method setCapacity (line 49) | private void setCapacity(int newCapacity) { method checkCapacity (line 64) | private void checkCapacity(int capacity) { method evict (line 76) | private Entry evict() { method get (line 95) | public V get(K key) { method put (line 112) | public void put(K key, V value) { method addNewEntry (line 137) | private void addNewEntry(Entry newEntry) { method moveEntryToLast (line 154) | private void moveEntryToLast(Entry entry) { class Entry (line 182) | static final class Entry { method Entry (line 188) | Entry() { method Entry (line 191) | Entry(Entry preEntry, Entry nextEntry, I key, J value) { method getPreEntry (line 198) | public Entry getPreEntry() { method setPreEntry (line 202) | public void setPreEntry(Entry preEntry) { method getNextEntry (line 206) | public Entry getNextEntry() { method setNextEntry (line 210) | public void setNextEntry(Entry nextEntry) { method getKey (line 214) | public I getKey() { method setKey (line 218) | public void setKey(I key) { method getValue (line 222) | public J getValue() { method setValue (line 226) | public void setValue(J value) { FILE: src/main/java/com/thealgorithms/datastructures/caches/RRCache.java class RRCache (line 36) | public final class RRCache { class CacheEntry (line 55) | private static class CacheEntry { method CacheEntry (line 65) | CacheEntry(V value, long ttlMillis) { method isExpired (line 75) | boolean isExpired() { method RRCache (line 89) | private RRCache(Builder builder) { method get (line 112) | public V get(K key) { method put (line 146) | public void put(K key, V value) { method put (line 163) | public void put(K key, V value, long ttlMillis) { method evictExpired (line 201) | private int evictExpired() { method removeKey (line 225) | private void removeKey(K key) { method notifyEviction (line 240) | private void notifyEviction(K key, V value) { method getHits (line 255) | public long getHits() { method getMisses (line 269) | public long getMisses() { method size (line 283) | public int size() { method getEvictionStrategy (line 310) | public EvictionStrategy getEvictionStrategy() { method toString (line 323) | @Override type EvictionStrategy (line 349) | public interface EvictionStrategy { method onAccess (line 356) | int onAccess(RRCache cache); class NoEvictionStrategy (line 365) | public static class NoEvictionStrategy implements EvictionStrate... method onAccess (line 366) | @Override class PeriodicEvictionStrategy (line 381) | public static class PeriodicEvictionStrategy implements Eviction... method PeriodicEvictionStrategy (line 391) | public PeriodicEvictionStrategy(int interval) { method onAccess (line 398) | @Override class Builder (line 417) | public static class Builder { method Builder (line 429) | public Builder(int capacity) { method defaultTTL (line 443) | public Builder defaultTTL(long ttlMillis) { method random (line 458) | public Builder random(Random r) { method evictionListener (line 473) | public Builder evictionListener(BiConsumer listener) { method build (line 486) | public RRCache build() { method evictionStrategy (line 497) | public Builder evictionStrategy(EvictionStrategy strateg... FILE: src/main/java/com/thealgorithms/datastructures/crdt/GCounter.java class GCounter (line 19) | class GCounter { method GCounter (line 29) | GCounter(int myId, int n) { method increment (line 42) | public void increment() { method value (line 51) | public int value() { method compare (line 65) | public boolean compare(GCounter other) { method merge (line 79) | public void merge(GCounter other) { FILE: src/main/java/com/thealgorithms/datastructures/crdt/GSet.java class GSet (line 17) | public class GSet { method GSet (line 23) | public GSet() { method addElement (line 32) | public void addElement(T e) { method lookup (line 42) | public boolean lookup(T e) { method compare (line 52) | public boolean compare(GSet other) { method merge (line 62) | public void merge(GSet other) { FILE: src/main/java/com/thealgorithms/datastructures/crdt/LWWElementSet.java class LWWElementSet (line 23) | class LWWElementSet { method LWWElementSet (line 32) | LWWElementSet() { method add (line 44) | public void add(T key) { method remove (line 54) | public void remove(T key) { method lookup (line 68) | public boolean lookup(T key) { method merge (line 83) | public void merge(LWWElementSet other) { method resolveConflict (line 101) | private Element resolveConflict(Element e1, Element e2) { class Element (line 112) | class Element { method Element (line 122) | Element(T key, Instant timestamp) { FILE: src/main/java/com/thealgorithms/datastructures/crdt/ORSet.java class ORSet (line 24) | public class ORSet { method ORSet (line 32) | public ORSet() { method contains (line 43) | public boolean contains(T element) { method elements (line 52) | public Set elements() { method add (line 63) | public void add(T element) { method remove (line 73) | public void remove(T element) { method prepare (line 84) | private Set> prepare(T element) { method prepare (line 99) | private String prepare() { method effect (line 109) | private void effect(T element, String n) { method effect (line 120) | private void effect(Set> pairsToRemove) { method generateUniqueTag (line 130) | private String generateUniqueTag() { method compare (line 140) | public boolean compare(ORSet other) { method merge (line 155) | public void merge(ORSet other) { class Pair (line 167) | public static class Pair { method Pair (line 177) | public Pair(T element, String uniqueTag) { method getElement (line 187) | public T getElement() { FILE: src/main/java/com/thealgorithms/datastructures/crdt/PNCounter.java class PNCounter (line 19) | class PNCounter { method PNCounter (line 31) | PNCounter(int myId, int n) { method increment (line 46) | public void increment() { method decrement (line 53) | public void decrement() { method value (line 62) | public int value() { method compare (line 74) | public boolean compare(PNCounter other) { method merge (line 91) | public void merge(PNCounter other) { FILE: src/main/java/com/thealgorithms/datastructures/crdt/TwoPSet.java class TwoPSet (line 18) | public class TwoPSet { method TwoPSet (line 25) | public TwoPSet() { method lookup (line 36) | public boolean lookup(T element) { method add (line 45) | public void add(T element) { method remove (line 54) | public void remove(T element) { method compare (line 66) | public boolean compare(TwoPSet otherSet) { method merge (line 76) | public TwoPSet merge(TwoPSet otherSet) { FILE: src/main/java/com/thealgorithms/datastructures/disjointsetunion/DisjointSetUnion.java class DisjointSetUnion (line 14) | public class DisjointSetUnion { method makeSet (line 22) | public Node makeSet(final T value) { method findSet (line 33) | public Node findSet(Node node) { method unionSets (line 47) | public void unionSets(Node x, Node y) { FILE: src/main/java/com/thealgorithms/datastructures/disjointsetunion/DisjointSetUnionBySize.java class DisjointSetUnionBySize (line 18) | public class DisjointSetUnionBySize { class Node (line 23) | public static class Node { method Node (line 28) | public Node(T value) { method makeSet (line 40) | public Node makeSet(final T value) { method findSet (line 50) | public Node findSet(Node node) { method unionSets (line 63) | public void unionSets(Node x, Node y) { FILE: src/main/java/com/thealgorithms/datastructures/disjointsetunion/Node.java class Node (line 3) | public class Node { method Node (line 21) | public Node(final T data) { FILE: src/main/java/com/thealgorithms/datastructures/dynamicarray/DynamicArray.java class DynamicArray (line 20) | public class DynamicArray implements Iterable { method DynamicArray (line 33) | public DynamicArray(final int capacity) { method DynamicArray (line 45) | public DynamicArray() { method add (line 55) | public void add(final E element) { method put (line 69) | public void put(final int index, E element) { method get (line 89) | @SuppressWarnings("unchecked") method remove (line 105) | public E remove(final int index) { method getSize (line 120) | public int getSize() { method isEmpty (line 129) | public boolean isEmpty() { method contains (line 139) | public boolean contains(final E element) { method stream (line 153) | public Stream stream() { method ensureCapacity (line 163) | private void ensureCapacity(int minCapacity) { method fastRemove (line 177) | private void fastRemove(int index) { method toString (line 191) | @Override method iterator (line 201) | @Override class DynamicArrayIterator (line 209) | private final class DynamicArrayIterator implements Iterator { method DynamicArrayIterator (line 217) | DynamicArrayIterator() { method hasNext (line 226) | @Override method next (line 238) | @Override method remove (line 255) | @Override method checkForComodification (line 271) | private void checkForComodification() { method forEachRemaining (line 284) | @Override FILE: src/main/java/com/thealgorithms/datastructures/graphs/AStar.java class AStar (line 14) | public final class AStar { method AStar (line 15) | private AStar() { class Graph (line 21) | static class Graph { method Graph (line 24) | Graph(int size) { method getNeighbours (line 31) | private ArrayList getNeighbours(int from) { method addEdge (line 36) | private void addEdge(Edge edge) { class Edge (line 45) | private static class Edge { method Edge (line 50) | Edge(int from, int to, int weight) { method getFrom (line 56) | public int getFrom() { method getTo (line 60) | public int getTo() { method getWeight (line 64) | public int getWeight() { class PathAndDistance (line 72) | static class PathAndDistance { method PathAndDistance (line 77) | PathAndDistance(int distance, ArrayList path, int estimated) { method getDistance (line 83) | public int getDistance() { method getPath (line 87) | public ArrayList getPath() { method getEstimated (line 91) | public int getEstimated() { method initializeGraph (line 97) | static void initializeGraph(Graph graph, List data) { method aStar (line 112) | public static PathAndDistance aStar(int from, int to, Graph graph, int... FILE: src/main/java/com/thealgorithms/datastructures/graphs/BellmanFord.java class BellmanFord (line 5) | class BellmanFord /* method BellmanFord (line 19) | BellmanFord(int v, int e) { class Edge (line 25) | class Edge { method Edge (line 36) | Edge(int a, int b, int c) { method printPath (line 47) | void printPath(int[] p, int i) { method main (line 55) | public static void main(String[] args) { method go (line 60) | public void go() { method show (line 129) | public void show(int source, int end, method addEdge (line 177) | public void addEdge(int x, int y, int z) { // Adds unidirectional edge method getEdgeArray (line 181) | public Edge[] getEdgeArray() { FILE: src/main/java/com/thealgorithms/datastructures/graphs/BipartiteGraphDFS.java class BipartiteGraphDFS (line 31) | public final class BipartiteGraphDFS { method BipartiteGraphDFS (line 32) | private BipartiteGraphDFS() { method bipartite (line 47) | private static boolean bipartite(int v, ArrayList> ... method isBipartite (line 71) | public static boolean isBipartite(int v, ArrayList>... FILE: src/main/java/com/thealgorithms/datastructures/graphs/BoruvkaAlgorithm.java class BoruvkaAlgorithm (line 13) | final class BoruvkaAlgorithm { method BoruvkaAlgorithm (line 14) | private BoruvkaAlgorithm() { class Edge (line 20) | static class Edge { method Edge (line 25) | Edge(final int src, final int dest, final int weight) { class Graph (line 35) | static class Graph { method Graph (line 45) | Graph(final int vertex, final List edges) { class Component (line 65) | private static class Component { method Component (line 69) | Component(final int parent, final int rank) { class BoruvkaState (line 78) | private static class BoruvkaState { method BoruvkaState (line 83) | BoruvkaState(final Graph graph) { method merge (line 94) | void merge(final Edge[] cheapest) { method hasMoreEdgesToAdd (line 113) | boolean hasMoreEdgesToAdd() { method computeCheapestEdges (line 122) | private Edge[] computeCheapestEdges() { method initializeComponents (line 146) | private static Component[] initializeComponents(final Graph graph) { method find (line 162) | static int find(final Component[] components, final int i) { method union (line 176) | static void union(Component[] components, final int x, final int y) { method boruvkaMST (line 196) | static List boruvkaMST(final Graph graph) { method checkEdgeVertices (line 212) | private static void checkEdgeVertices(final int vertex, final int uppe... FILE: src/main/java/com/thealgorithms/datastructures/graphs/ConnectedComponent.java class Graph (line 12) | class Graph> { class Node (line 14) | class Node { method Node (line 18) | Node(E name) { class Edge (line 23) | class Edge { method Edge (line 28) | Edge(Node startNode, Node endNode) { method Graph (line 37) | Graph() { method addEdge (line 49) | public void addEdge(E startNode, E endNode) { method countGraphs (line 79) | public int countGraphs() { method depthFirstSearch (line 100) | public ArrayList depthFirstSearch(Node n, ArrayList visite... class ConnectedComponent (line 111) | public final class ConnectedComponent { method ConnectedComponent (line 112) | private ConnectedComponent() { method main (line 115) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/datastructures/graphs/Cycles.java class Cycle (line 6) | class Cycle { method Cycle (line 13) | Cycle() { method start (line 39) | public void start() { method dfs (line 50) | private void dfs(Integer start, Integer curr, ArrayList temp) { method printAll (line 71) | public void printAll() { class Cycles (line 82) | public final class Cycles { method Cycles (line 83) | private Cycles() { method main (line 86) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/datastructures/graphs/DialsAlgorithm.java class DialsAlgorithm (line 23) | public final class DialsAlgorithm { method DialsAlgorithm (line 27) | private DialsAlgorithm() { class Edge (line 32) | public static class Edge { method Edge (line 36) | public Edge(int destination, int weight) { method getDestination (line 41) | public int getDestination() { method getWeight (line 45) | public int getWeight() { method run (line 60) | public static int[] run(List> graph, int source, int maxEdg... FILE: src/main/java/com/thealgorithms/datastructures/graphs/DijkstraAlgorithm.java class DijkstraAlgorithm (line 8) | public class DijkstraAlgorithm { method DijkstraAlgorithm (line 17) | public DijkstraAlgorithm(int vertexCount) { method run (line 32) | public int[] run(int[][] graph, int source) { method getMinDistanceVertex (line 66) | private int getMinDistanceVertex(int[] distances, boolean[] processed) { method printDistances (line 85) | private void printDistances(int[] distances) { FILE: src/main/java/com/thealgorithms/datastructures/graphs/DijkstraOptimizedAlgorithm.java class DijkstraOptimizedAlgorithm (line 11) | public class DijkstraOptimizedAlgorithm { method DijkstraOptimizedAlgorithm (line 20) | public DijkstraOptimizedAlgorithm(int vertexCount) { method run (line 35) | public int[] run(int[][] graph, int source) { FILE: src/main/java/com/thealgorithms/datastructures/graphs/EdmondsBlossomAlgorithm.java class EdmondsBlossomAlgorithm (line 19) | public final class EdmondsBlossomAlgorithm { method EdmondsBlossomAlgorithm (line 21) | private EdmondsBlossomAlgorithm() { method maximumMatching (line 33) | public static List maximumMatching(Iterable edges, int v... method updateMatching (line 134) | private static void updateMatching(int[] match, int[] parent, int u) { method findBase (line 153) | private static int findBase(int[] base, int[] parent, int u, int v) { method contractBlossom (line 183) | private static void contractBlossom(BlossomData blossomData) { class BlossomAuxData (line 217) | static class BlossomAuxData { method BlossomAuxData (line 225) | BlossomAuxData(Queue queue, int[] parent, int[] base, boole... class BlossomData (line 238) | static class BlossomData { method BlossomData (line 244) | BlossomData(BlossomAuxData auxData, int u, int v, int lca) { FILE: src/main/java/com/thealgorithms/datastructures/graphs/FloydWarshall.java class FloydWarshall (line 17) | public class FloydWarshall { method FloydWarshall (line 29) | public FloydWarshall(int numberofvertices) { method floydwarshall (line 42) | public void floydwarshall(int[][] adjacencyMatrix) { method printDistanceMatrix (line 65) | private void printDistanceMatrix() { method getDistanceMatrix (line 82) | public Object[] getDistanceMatrix() { FILE: src/main/java/com/thealgorithms/datastructures/graphs/FordFulkerson.java class FordFulkerson (line 14) | public final class FordFulkerson { method FordFulkerson (line 17) | private FordFulkerson() { method networkFlow (line 30) | public static int networkFlow(int vertexCount, int[][] capacity, int[]... FILE: src/main/java/com/thealgorithms/datastructures/graphs/Graphs.java class AdjacencyListGraph (line 5) | class AdjacencyListGraph> { method AdjacencyListGraph (line 9) | AdjacencyListGraph() { class Vertex (line 13) | private class Vertex { method Vertex (line 18) | Vertex(E data) { method addAdjacentVertex (line 23) | public boolean addAdjacentVertex(Vertex to) { method removeAdjacentVertex (line 32) | public boolean removeAdjacentVertex(E to) { method removeEdge (line 55) | public boolean removeEdge(E from, E to) { method addEdge (line 77) | public boolean addEdge(E from, E to) { method toString (line 106) | @Override class Graphs (line 124) | public final class Graphs { method Graphs (line 125) | private Graphs() { method main (line 128) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/datastructures/graphs/HamiltonianCycle.java class HamiltonianCycle (line 15) | public class HamiltonianCycle { method findHamiltonianCycle (line 30) | public int[] findHamiltonianCycle(int[][] graph) { method isPathFound (line 60) | public boolean isPathFound(int vertex) { method isPresent (line 98) | public boolean isPresent(int vertex) { FILE: src/main/java/com/thealgorithms/datastructures/graphs/JohnsonsAlgorithm.java class JohnsonsAlgorithm (line 22) | public final class JohnsonsAlgorithm { method JohnsonsAlgorithm (line 26) | private JohnsonsAlgorithm() { method johnsonAlgorithm (line 40) | public static double[][] johnsonAlgorithm(double[][] graph) { method convertToEdgeList (line 62) | public static double[][] convertToEdgeList(double[][] graph) { method bellmanFord (line 86) | private static double[] bellmanFord(double[][] edges, int numVertices) { method reweightGraph (line 129) | public static double[][] reweightGraph(double[][] graph, double[] modi... method dijkstra (line 153) | public static double[] dijkstra(double[][] reweightedGraph, int source... method minDistance (line 189) | public static int minDistance(double[] dist, boolean[] visited) { FILE: src/main/java/com/thealgorithms/datastructures/graphs/KahnsAlgorithm.java class AdjacencyList (line 18) | class AdjacencyList> { method AdjacencyList (line 25) | AdjacencyList() { method addEdge (line 36) | void addEdge(E from, E to) { method getAdjacents (line 52) | ArrayList getAdjacents(E v) { method getVertices (line 61) | Set getVertices() { class TopologicalSort (line 72) | class TopologicalSort> { method TopologicalSort (line 82) | TopologicalSort(AdjacencyList graph) { method calculateInDegree (line 90) | void calculateInDegree() { method topSortOrder (line 108) | ArrayList topSortOrder() { class KahnsAlgorithm (line 145) | public final class KahnsAlgorithm { method KahnsAlgorithm (line 146) | private KahnsAlgorithm() { method main (line 149) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/datastructures/graphs/Kosaraju.java class Kosaraju (line 58) | public class Kosaraju { method kosaraju (line 81) | public List> kosaraju(int v, List> list) { method sortEdgesByLowestFinishTime (line 93) | private void sortEdgesByLowestFinishTime(int v, List> li... method createTransposeMatrix (line 108) | private List> createTransposeMatrix(int v, List>... method dfs (line 144) | private void dfs(int node, int[] vis, List> list) { method dfs2 (line 160) | private void dfs2(int node, int[] vis, List> list) { FILE: src/main/java/com/thealgorithms/datastructures/graphs/Kruskal.java class Kruskal (line 22) | @SuppressWarnings({"rawtypes", "unchecked"}) class Edge (line 28) | static class Edge { method Edge (line 34) | Edge(int from, int to, int weight) { method addEdge (line 49) | static void addEdge(HashSet[] graph, int from, int to, int weigh... method kruskal (line 59) | public HashSet[] kruskal(HashSet[] graph) { FILE: src/main/java/com/thealgorithms/datastructures/graphs/MatrixGraphs.java class MatrixGraphs (line 15) | public final class MatrixGraphs { method MatrixGraphs (line 16) | private MatrixGraphs() { method main (line 19) | public static void main(String[] args) { class AdjacencyMatrixGraph (line 46) | class AdjacencyMatrixGraph { method AdjacencyMatrixGraph (line 73) | AdjacencyMatrixGraph(int givenNumberOfVertices) { method setNumberOfVertices (line 89) | private void setNumberOfVertices(int newNumberOfVertices) { method numberOfVertices (line 98) | public int numberOfVertices() { method setNumberOfEdges (line 108) | private void setNumberOfEdges(int newNumberOfEdges) { method numberOfEdges (line 117) | public int numberOfEdges() { method setAdjacency (line 126) | private void setAdjacency(int[][] newAdjacency) { method adjacency (line 135) | private int[][] adjacency() { method adjacencyOfEdgeDoesExist (line 146) | private boolean adjacencyOfEdgeDoesExist(int from, int to) { method vertexDoesExist (line 156) | public boolean vertexDoesExist(int aVertex) { method edgeDoesExist (line 167) | public boolean edgeDoesExist(int from, int to) { method addEdge (line 183) | public boolean addEdge(int from, int to) { method removeEdge (line 204) | public boolean removeEdge(int from, int to) { method depthFirstOrder (line 223) | public List depthFirstOrder(int startVertex) { method depthFirstOrder (line 250) | private void depthFirstOrder(int currentVertex, boolean[] visited, Lis... method breadthFirstOrder (line 278) | public List breadthFirstOrder(int startVertex) { method toString (line 329) | public String toString() { FILE: src/main/java/com/thealgorithms/datastructures/graphs/PrimMST.java class PrimMST (line 7) | public class PrimMST { method minKey (line 14) | int minKey(int[] key, Boolean[] mstSet) { method primMST (line 29) | public int[] primMST(int[][] graph) { FILE: src/main/java/com/thealgorithms/datastructures/graphs/TarjansAlgorithm.java class TarjansAlgorithm (line 58) | public class TarjansAlgorithm { method stronglyConnectedComponents (line 73) | public List> stronglyConnectedComponents(int v, List getNeighbors(int node) { method getEdgeWeight (line 58) | public Integer getEdgeWeight(int orig, int dest) { method size (line 66) | public int size() { FILE: src/main/java/com/thealgorithms/datastructures/graphs/WelshPowell.java class WelshPowell (line 25) | @SuppressWarnings({"rawtypes", "unchecked"}) method WelshPowell (line 29) | private WelshPowell() { class Graph (line 35) | static final class Graph { method Graph (line 44) | private Graph(int vertices) { method addEdge (line 60) | private void addEdge(int nodeA, int nodeB) { method validateVertex (line 76) | private void validateVertex(int vertex) { method getAdjacencyList (line 88) | HashSet getAdjacencyList(int vertex) { method getNumVertices (line 97) | int getNumVertices() { method makeGraph (line 110) | public static Graph makeGraph(int numberOfVertices, int[][] listOfEdge... method findColoring (line 127) | public static int[] findColoring(Graph graph) { method isBlank (line 151) | private static boolean isBlank(int color) { method isAdjacentToColored (line 163) | private static boolean isAdjacentToColored(Graph graph, int vertex, in... method initializeColors (line 173) | private static int[] initializeColors(int numberOfVertices) { method getSortedNodes (line 185) | private static Integer[] getSortedNodes(final Graph graph) { method computeUsedColors (line 197) | private static boolean[] computeUsedColors(final Graph graph, final in... method firstUnusedColor (line 209) | private static int firstUnusedColor(boolean[] usedColors) { FILE: src/main/java/com/thealgorithms/datastructures/hashmap/hashing/GenericHashMapUsingArray.java class GenericHashMapUsingArray (line 26) | @SuppressWarnings({"rawtypes", "unchecked"}) method GenericHashMapUsingArray (line 35) | public GenericHashMapUsingArray() { method initBuckets (line 45) | private void initBuckets(int n) { method put (line 59) | public void put(K key, V value) { method hashFunction (line 88) | private int hashFunction(K key) { method reHash (line 95) | private void reHash() { method remove (line 112) | public void remove(K key) { method size (line 135) | public int size() { method get (line 145) | public V get(K key) { method toString (line 156) | @Override method containsKey (line 182) | public boolean containsKey(K key) { class Node (line 189) | public class Node { method Node (line 199) | public Node(K key, V value) { FILE: src/main/java/com/thealgorithms/datastructures/hashmap/hashing/GenericHashMapUsingArrayList.java class GenericHashMapUsingArrayList (line 26) | public class GenericHashMapUsingArrayList { method GenericHashMapUsingArrayList (line 34) | public GenericHashMapUsingArrayList() { method put (line 49) | public void put(K key, V value) { method reHash (line 73) | private void reHash() { method get (line 93) | public V get(K key) { method remove (line 109) | public void remove(K key) { method containsKey (line 132) | public boolean containsKey(K key) { method size (line 141) | public int size() { method toString (line 150) | @Override class Node (line 173) | private class Node { method Node (line 183) | Node(K key, V val) { FILE: src/main/java/com/thealgorithms/datastructures/hashmap/hashing/HashMap.java class HashMap (line 11) | @SuppressWarnings("rawtypes") method HashMap (line 21) | @SuppressWarnings("unchecked") method computeHash (line 38) | private int computeHash(K key) { method insert (line 53) | public void insert(K key, V value) { method delete (line 63) | public void delete(K key) { method search (line 74) | public V search(K key) { method display (line 83) | public void display() { method clear (line 92) | public void clear() { method size (line 103) | public int size() { class LinkedList (line 117) | public static class LinkedList { method insert (line 128) | public void insert(K key, V value) { method findEnd (line 148) | private Node findEnd(Node node) { method findKey (line 161) | public Node findKey(K key) { method delete (line 178) | public void delete(K key) { method display (line 205) | public String display() { method display (line 215) | private String display(Node node) { method isEmpty (line 232) | public boolean isEmpty() { class Node (line 243) | public static class Node { method Node (line 254) | public Node(K key, V value) { method getKey (line 264) | public K getKey() { method getValue (line 273) | public V getValue() { method setValue (line 277) | public void setValue(V value) { // This method allows updating the v... method getNext (line 286) | public Node getNext() { method setNext (line 295) | public void setNext(Node next) { FILE: src/main/java/com/thealgorithms/datastructures/hashmap/hashing/HashMapCuckooHashing.java class HashMapCuckooHashing (line 14) | public class HashMapCuckooHashing { method HashMapCuckooHashing (line 27) | public HashMapCuckooHashing(int tableSize) { method hashFunction1 (line 41) | public int hashFunction1(int key) { method hashFunction2 (line 55) | public int hashFunction2(int key) { method insertKey2HashTable (line 73) | public void insertKey2HashTable(int key) { method reHashTableIncreasesTableSize (line 127) | public void reHashTableIncreasesTableSize() { method deleteKeyFromHashTable (line 145) | public void deleteKeyFromHashTable(int key) { method displayHashtable (line 170) | public void displayHashtable() { method findKeyInTable (line 188) | public int findKeyInTable(int key) { method checkTableContainsKey (line 214) | public boolean checkTableContainsKey(int key) { method checkLoadFactor (line 224) | public double checkLoadFactor() { method isFull (line 238) | public boolean isFull() { method isEmpty (line 252) | public boolean isEmpty() { method getNumberOfKeysInTable (line 266) | public int getNumberOfKeysInTable() { FILE: src/main/java/com/thealgorithms/datastructures/hashmap/hashing/ImmutableHashMap.java class ImmutableHashMap (line 12) | public final class ImmutableHashMap { method ImmutableHashMap (line 22) | private ImmutableHashMap(Node[] table, int size) { method empty (line 34) | @SuppressWarnings({"unchecked", "rawtypes"}) method put (line 47) | public ImmutableHashMap put(K key, V value) { method get (line 61) | public V get(K key) { method containsKey (line 80) | public boolean containsKey(K key) { method size (line 89) | public int size() { method hash (line 96) | private int hash(K key) { class Node (line 103) | private static final class Node { method Node (line 109) | private Node(K key, V value, Node next) { FILE: src/main/java/com/thealgorithms/datastructures/hashmap/hashing/Intersection.java class Intersection (line 34) | public final class Intersection { method Intersection (line 36) | private Intersection() { method intersection (line 53) | public static List intersection(int[] arr1, int[] arr2) { FILE: src/main/java/com/thealgorithms/datastructures/hashmap/hashing/LinearProbingHashMap.java class LinearProbingHashMap (line 37) | @SuppressWarnings("rawtypes") method LinearProbingHashMap (line 45) | public LinearProbingHashMap() { method LinearProbingHashMap (line 49) | @SuppressWarnings("unchecked") method put (line 57) | @Override method get (line 81) | @Override method delete (line 96) | @Override method contains (line 130) | @Override method size (line 135) | @Override method keys (line 140) | @Override method increment (line 153) | private int increment(int i) { method resize (line 157) | private void resize(int newSize) { FILE: src/main/java/com/thealgorithms/datastructures/hashmap/hashing/MainCuckooHashing.java class MainCuckooHashing (line 5) | public final class MainCuckooHashing { method MainCuckooHashing (line 6) | private MainCuckooHashing() { method main (line 9) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/datastructures/hashmap/hashing/MajorityElement.java class MajorityElement (line 15) | public final class MajorityElement { method MajorityElement (line 16) | private MajorityElement() { method majority (line 25) | public static List majority(int[] nums) { FILE: src/main/java/com/thealgorithms/datastructures/hashmap/hashing/Map.java class Map (line 3) | public abstract class Map { method put (line 5) | abstract boolean put(Key key, Value value); method get (line 7) | abstract Value get(Key key); method delete (line 9) | abstract boolean delete(Key key); method keys (line 11) | abstract Iterable keys(); method size (line 13) | abstract int size(); method contains (line 15) | public boolean contains(Key key) { method hash (line 19) | protected int hash(Key key, int size) { FILE: src/main/java/com/thealgorithms/datastructures/heaps/EmptyHeapException.java class EmptyHeapException (line 7) | @SuppressWarnings("serial") method EmptyHeapException (line 10) | public EmptyHeapException(String message) { method EmptyHeapException (line 14) | public EmptyHeapException(String message, Throwable cause) { FILE: src/main/java/com/thealgorithms/datastructures/heaps/FibonacciHeap.java class FibonacciHeap (line 28) | public class FibonacciHeap { method FibonacciHeap (line 42) | public FibonacciHeap() { method FibonacciHeap (line 52) | public FibonacciHeap(int key) { method empty (line 62) | public boolean empty() { method insert (line 74) | public HeapNode insert(int key) { method deleteMin (line 93) | public void deleteMin() { method findMin (line 131) | public HeapNode findMin() { method meld (line 141) | public void meld(FibonacciHeap heap2) { method size (line 159) | public int size() { method countersRep (line 167) | public int[] countersRep() { method delete (line 187) | public void delete(HeapNode x) { method decreaseKey (line 198) | private void decreaseKey(HeapNode x, int delta) { method potential (line 217) | public int potential() { method totalLinks (line 226) | public static int totalLinks() { method totalCuts (line 235) | public static int totalCuts() { method updateMin (line 243) | private void updateMin(HeapNode posMin) { method cascadingCuts (line 256) | private void cascadingCuts(HeapNode curr) { method cut (line 277) | private void cut(HeapNode curr) { method successiveLink (line 304) | private void successiveLink(HeapNode curr) { method toBuckets (line 312) | private HeapNode[] toBuckets(HeapNode curr) { method fromBuckets (line 333) | private HeapNode fromBuckets(HeapNode[] buckets) { method link (line 358) | private HeapNode link(HeapNode c1, HeapNode c2) { class HeapNode (line 379) | public class HeapNode { method HeapNode (line 394) | public HeapNode(int key) { method getKey (line 404) | public int getKey() { method isMarked (line 412) | private boolean isMarked() { method mark (line 420) | private void mark() { method setNext (line 431) | private void setNext(HeapNode newNext) { method getNext (line 442) | private HeapNode getNext() { method isRoot (line 450) | private boolean isRoot() { FILE: src/main/java/com/thealgorithms/datastructures/heaps/GenericHeap.java class GenericHeap (line 11) | public class GenericHeap> { method add (line 21) | public void add(T item) { method upHeapify (line 36) | private void upHeapify(int ci) { method size (line 49) | public int size() { method isEmpty (line 58) | public boolean isEmpty() { method remove (line 67) | public T remove() { method downHeapify (line 83) | private void downHeapify(int pi) { method get (line 104) | public T get() { method isLarger (line 118) | private int isLarger(T t, T o) { method swap (line 128) | private void swap(int i, int j) { method updatePriority (line 142) | public void updatePriority(T item) { FILE: src/main/java/com/thealgorithms/datastructures/heaps/Heap.java type Heap (line 21) | public interface Heap { method getElement (line 27) | HeapElement getElement() throws EmptyHeapException; method insertElement (line 35) | void insertElement(HeapElement element); method deleteElement (line 43) | void deleteElement(int elementIndex) throws EmptyHeapException; FILE: src/main/java/com/thealgorithms/datastructures/heaps/HeapElement.java class HeapElement (line 25) | public class HeapElement { method HeapElement (line 37) | public HeapElement(double key, Object info) { method HeapElement (line 48) | public HeapElement(int key, Object info) { method HeapElement (line 59) | public HeapElement(Integer key, Object info) { method HeapElement (line 70) | public HeapElement(Double key, Object info) { method HeapElement (line 80) | public HeapElement(double key) { method HeapElement (line 90) | public HeapElement(int key) { method HeapElement (line 100) | public HeapElement(Integer key) { method HeapElement (line 110) | public HeapElement(Double key) { method getInfo (line 121) | public Object getInfo() { method getKey (line 130) | public double getKey() { method toString (line 140) | @Override method equals (line 150) | @Override method hashCode (line 163) | @Override method getValue (line 170) | public String getValue() { FILE: src/main/java/com/thealgorithms/datastructures/heaps/IndexedPriorityQueue.java class IndexedPriorityQueue (line 42) | public class IndexedPriorityQueue { method IndexedPriorityQueue (line 67) | public IndexedPriorityQueue() { method IndexedPriorityQueue (line 71) | public IndexedPriorityQueue(Comparator cmp) { method IndexedPriorityQueue (line 75) | public IndexedPriorityQueue(int initialCapacity, Comparator... method size (line 85) | public int size() { method isEmpty (line 90) | public boolean isEmpty() { method peek (line 98) | @SuppressWarnings("unchecked") method offer (line 109) | public boolean offer(E e) { method poll (line 123) | @SuppressWarnings("unchecked") method remove (line 137) | public boolean remove(Object o) { method contains (line 147) | public boolean contains(Object o) { method clear (line 152) | public void clear() { method changeKey (line 171) | public void changeKey(E e, Consumer mutator) { method decreaseKey (line 188) | public void decreaseKey(E e, Consumer mutator) { method increaseKey (line 201) | public void increaseKey(E e, Consumer mutator) { method grow (line 215) | private void grow(int minCapacity) { method compare (line 222) | @SuppressWarnings("unchecked") method siftUp (line 234) | @SuppressWarnings("unchecked") method siftUp (line 254) | @SuppressWarnings("unchecked") method siftDown (line 277) | @SuppressWarnings("unchecked") method removeAt (line 307) | @SuppressWarnings("unchecked") FILE: src/main/java/com/thealgorithms/datastructures/heaps/KthElementFinder.java class KthElementFinder (line 13) | public final class KthElementFinder { method KthElementFinder (line 14) | private KthElementFinder() { method findKthLargest (line 28) | public static int findKthLargest(int[] nums, int k) { method findKthSmallest (line 50) | public static int findKthSmallest(int[] nums, int k) { FILE: src/main/java/com/thealgorithms/datastructures/heaps/LeftistHeap.java class LeftistHeap (line 23) | public class LeftistHeap { class Node (line 25) | private static final class Node { method Node (line 32) | private Node(int element) { method LeftistHeap (line 43) | public LeftistHeap() { method isEmpty (line 52) | public boolean isEmpty() { method clear (line 59) | public void clear() { method merge (line 68) | public void merge(LeftistHeap h1) { method merge (line 81) | public Node merge(Node a, Node b) { method insert (line 120) | public void insert(int a) { method extractMin (line 129) | public int extractMin() { method inOrder (line 144) | public ArrayList inOrder() { method inOrderAux (line 156) | private void inOrderAux(Node n, ArrayList lst) { FILE: src/main/java/com/thealgorithms/datastructures/heaps/MaxHeap.java class MaxHeap (line 29) | public class MaxHeap implements Heap { method MaxHeap (line 41) | public MaxHeap(List listElements) { method heapifyDown (line 67) | private void heapifyDown(int elementIndex) { method getElement (line 97) | public HeapElement getElement(int elementIndex) { method getElementKey (line 111) | private double getElementKey(int elementIndex) { method swap (line 124) | private void swap(int index1, int index2) { method toggleUp (line 136) | private void toggleUp(int elementIndex) { method toggleDown (line 150) | private void toggleDown(int elementIndex) { method extractMax (line 175) | private HeapElement extractMax() throws EmptyHeapException { method insertElement (line 187) | @Override method deleteElement (line 199) | @Override method getElement (line 226) | @Override method size (line 236) | public int size() { method isEmpty (line 245) | public boolean isEmpty() { FILE: src/main/java/com/thealgorithms/datastructures/heaps/MedianFinder.java class MedianFinder (line 19) | public final class MedianFinder { method MedianFinder (line 20) | MedianFinder() { method addNum (line 32) | public void addNum(int num) { method findMedian (line 53) | public double findMedian() { FILE: src/main/java/com/thealgorithms/datastructures/heaps/MergeKSortedArrays.java class MergeKSortedArrays (line 17) | public final class MergeKSortedArrays { method MergeKSortedArrays (line 18) | private MergeKSortedArrays() { method mergeKArrays (line 36) | public static int[] mergeKArrays(int[][] arrays) { FILE: src/main/java/com/thealgorithms/datastructures/heaps/MinHeap.java class MinHeap (line 29) | public class MinHeap implements Heap { method MinHeap (line 40) | public MinHeap(List listElements) { method getElement (line 74) | public HeapElement getElement(int elementIndex) { method getElementKey (line 88) | private double getElementKey(int elementIndex) { method swap (line 101) | private void swap(int index1, int index2) { method heapifyDown (line 113) | private void heapifyDown(int elementIndex) { method toggleUp (line 145) | private void toggleUp(int elementIndex) { method toggleDown (line 166) | private void toggleDown(int elementIndex) { method extractMin (line 198) | private HeapElement extractMin() throws EmptyHeapException { method insertElement (line 210) | @Override method deleteElement (line 222) | @Override method getElement (line 249) | @Override method size (line 259) | public int size() { method isEmpty (line 268) | public boolean isEmpty() { FILE: src/main/java/com/thealgorithms/datastructures/heaps/MinPriorityQueue.java class MinPriorityQueue (line 22) | public class MinPriorityQueue { method MinPriorityQueue (line 33) | public MinPriorityQueue(int c) { method insert (line 44) | public void insert(int key) { method peek (line 67) | public int peek() { method isEmpty (line 79) | public boolean isEmpty() { method isFull (line 88) | public boolean isFull() { method print (line 95) | public void print() { method heapSort (line 105) | public void heapSort() { method sink (line 114) | private void sink() { method delete (line 145) | public int delete() { FILE: src/main/java/com/thealgorithms/datastructures/lists/CircleLinkedList.java class CircleLinkedList (line 13) | @SuppressWarnings("rawtypes") class Node (line 21) | static final class Node { method Node (line 26) | private Node(E value, Node next) { method CircleLinkedList (line 40) | public CircleLinkedList() { method getSize (line 51) | public int getSize() { method append (line 62) | public void append(E value) { method toString (line 82) | public String toString() { method remove (line 107) | public E remove(int pos) { FILE: src/main/java/com/thealgorithms/datastructures/lists/CircularDoublyLinkedList.java class CircularDoublyLinkedList (line 17) | public class CircularDoublyLinkedList { class Node (line 18) | static final class Node { method Node (line 23) | private Node(E value, Node next, Node prev) { method CircularDoublyLinkedList (line 38) | public CircularDoublyLinkedList() { method getSize (line 50) | public int getSize() { method append (line 62) | public void append(E value) { method toString (line 79) | public String toString() { method remove (line 104) | public E remove(int pos) { FILE: src/main/java/com/thealgorithms/datastructures/lists/CountSinglyLinkedListRecursion.java class CountSinglyLinkedListRecursion (line 7) | public class CountSinglyLinkedListRecursion extends SinglyLinkedList { method countRecursion (line 15) | private int countRecursion(SinglyLinkedListNode head) { method count (line 25) | @Override FILE: src/main/java/com/thealgorithms/datastructures/lists/CreateAndDetectLoop.java class CreateAndDetectLoop (line 9) | public final class CreateAndDetectLoop { method CreateAndDetectLoop (line 14) | private CreateAndDetectLoop() { class Node (line 22) | static final class Node { method Node (line 26) | Node(int data) { method createLoop (line 42) | static void createLoop(Node head, int position1, int position2) { method detectLoop (line 79) | static boolean detectLoop(Node head) { FILE: src/main/java/com/thealgorithms/datastructures/lists/CursorLinkedList.java class CursorLinkedList (line 13) | @SuppressWarnings({"rawtypes", "unchecked"}) class Node (line 20) | private static class Node { method Node (line 24) | Node(T element, int next) { method CursorLinkedList (line 48) | public CursorLinkedList() { method printList (line 57) | public void printList() { method indexOf (line 75) | public int indexOf(T element) { method get (line 100) | public T get(int position) { method removeByIndex (line 121) | public void removeByIndex(int index) { method remove (line 134) | public void remove(T element) { method alloc (line 164) | private int alloc() { method free (line 179) | private void free(int index) { method append (line 193) | public void append(T element) { FILE: src/main/java/com/thealgorithms/datastructures/lists/DoublyLinkedList.java class DoublyLinkedList (line 16) | public final class DoublyLinkedList { method DoublyLinkedList (line 34) | public DoublyLinkedList() { method DoublyLinkedList (line 45) | public DoublyLinkedList(int[] array) { method isEmpty (line 59) | public boolean isEmpty() { method display (line 66) | public void display() { // Prints contents of the list method displayBackwards (line 78) | public void displayBackwards() { class Link (line 93) | class Link { method Link (line 113) | Link(int value) { method displayLink (line 120) | public void displayLink() { method main (line 129) | public static void main(String[] args) { class LinkOperations (line 172) | class LinkOperations { method insertHead (line 193) | public void insertHead(int x, DoublyLinkedList doublyLinkedList) { method insertTail (line 210) | public void insertTail(int x, DoublyLinkedList doublyLinkedList) { method insertElementByIndex (line 230) | public void insertElementByIndex(int x, int index, DoublyLinkedList do... method deleteHead (line 260) | public Link deleteHead() { method deleteTail (line 279) | public Link deleteTail() { method delete (line 298) | public void delete(int x) { method insertOrdered (line 325) | public void insertOrdered(int x, DoublyLinkedList doublyLinkedList) { method deleteNode (line 350) | public void deleteNode(Link z) { method removeDuplicates (line 362) | public void removeDuplicates(DoublyLinkedList l) { method reverse (line 379) | public void reverse() { method clearList (line 405) | public void clearList() { FILE: src/main/java/com/thealgorithms/datastructures/lists/FlattenMultilevelLinkedList.java class FlattenMultilevelLinkedList (line 16) | public final class FlattenMultilevelLinkedList { method FlattenMultilevelLinkedList (line 20) | private FlattenMultilevelLinkedList() { class Node (line 27) | static class Node { method Node (line 32) | Node(int data) { method merge (line 47) | private static Node merge(Node a, Node b) { method flatten (line 77) | public static Node flatten(Node head) { FILE: src/main/java/com/thealgorithms/datastructures/lists/MergeKSortedLinkedList.java class MergeKSortedLinkedList (line 28) | public class MergeKSortedLinkedList { method mergeKList (line 41) | Node mergeKList(Node[] a, int n) { class Node (line 80) | static class Node { method Node (line 84) | Node(int data) { method Node (line 89) | Node(int data, Node next) { FILE: src/main/java/com/thealgorithms/datastructures/lists/MergeSortedArrayList.java class MergeSortedArrayList (line 30) | public final class MergeSortedArrayList { method MergeSortedArrayList (line 32) | private MergeSortedArrayList() { method merge (line 46) | public static void merge(List listA, List listB, Col... FILE: src/main/java/com/thealgorithms/datastructures/lists/MergeSortedSinglyLinkedList.java class MergeSortedSinglyLinkedList (line 27) | public class MergeSortedSinglyLinkedList extends SinglyLinkedList { method merge (line 40) | public static SinglyLinkedList merge(SinglyLinkedList listA, SinglyLin... FILE: src/main/java/com/thealgorithms/datastructures/lists/MiddleOfLinkedList.java class MiddleOfLinkedList (line 20) | public final class MiddleOfLinkedList { method MiddleOfLinkedList (line 22) | private MiddleOfLinkedList() { method middleNode (line 31) | public static SinglyLinkedListNode middleNode(final SinglyLinkedListNo... FILE: src/main/java/com/thealgorithms/datastructures/lists/QuickSortLinkedList.java class QuickSortLinkedList (line 105) | public class QuickSortLinkedList { method QuickSortLinkedList (line 115) | public QuickSortLinkedList(SinglyLinkedList list) { method sortList (line 124) | public void sortList() { method sortList (line 139) | private SinglyLinkedListNode sortList(SinglyLinkedListNode head) { FILE: src/main/java/com/thealgorithms/datastructures/lists/RandomNode.java class RandomNode (line 30) | public class RandomNode { class ListNode (line 36) | static class ListNode { method ListNode (line 41) | ListNode(int val) { method RandomNode (line 46) | public RandomNode(ListNode head) { method getRandom (line 59) | public int getRandom() { method main (line 78) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/datastructures/lists/ReverseKGroup.java class ReverseKGroup (line 33) | public class ReverseKGroup { method length (line 41) | public int length(SinglyLinkedListNode head) { method reverse (line 59) | public SinglyLinkedListNode reverse(SinglyLinkedListNode head, int cou... method reverseKGroup (line 88) | public SinglyLinkedListNode reverseKGroup(SinglyLinkedListNode head, i... FILE: src/main/java/com/thealgorithms/datastructures/lists/RotateSinglyLinkedLists.java class RotateSinglyLinkedLists (line 32) | public class RotateSinglyLinkedLists { method rotateRight (line 41) | public SinglyLinkedListNode rotateRight(SinglyLinkedListNode head, int... FILE: src/main/java/com/thealgorithms/datastructures/lists/SearchSinglyLinkedListRecursion.java class SearchSinglyLinkedListRecursion (line 24) | public class SearchSinglyLinkedListRecursion extends SinglyLinkedList { method searchRecursion (line 33) | private boolean searchRecursion(SinglyLinkedListNode node, int key) { method search (line 43) | @Override FILE: src/main/java/com/thealgorithms/datastructures/lists/SinglyLinkedList.java class SinglyLinkedList (line 10) | public class SinglyLinkedList implements Iterable { method SinglyLinkedList (line 25) | public SinglyLinkedList() { method SinglyLinkedList (line 36) | public SinglyLinkedList(SinglyLinkedListNode head, int size) { method detectLoop (line 46) | public boolean detectLoop() { method middle (line 64) | public SinglyLinkedListNode middle() { method swapNodes (line 81) | public void swapNodes(int valueFirst, int valueSecond) { method reverseListIter (line 129) | public SinglyLinkedListNode reverseListIter(SinglyLinkedListNode node) { method reverseListRec (line 152) | public SinglyLinkedListNode reverseListRec(SinglyLinkedListNode head) { method clear (line 169) | public void clear() { method isEmpty (line 183) | public boolean isEmpty() { method size (line 192) | public int size() { method getHead (line 201) | public SinglyLinkedListNode getHead() { method setHead (line 209) | public void setHead(SinglyLinkedListNode head) { method count (line 218) | public int count() { method search (line 233) | public boolean search(final int key) { method toString (line 242) | @Override method deleteDuplicates (line 251) | public void deleteDuplicates() { method print (line 275) | public void print() { method insertHead (line 292) | public void insertHead(int x) { method insert (line 301) | public void insert(int data) { method insertNth (line 311) | public void insertNth(int data, int position) { method deleteHead (line 340) | public void deleteHead() { method delete (line 347) | public void delete() { method deleteNth (line 354) | public void deleteNth(int position) { method getNth (line 377) | public int getNth(int index) { method checkBounds (line 393) | public void checkBounds(int position, int low, int high) { method main (line 402) | public static void main(String[] arg) { method iterator (line 449) | @Override class SinglyLinkedListIterator (line 454) | private class SinglyLinkedListIterator implements Iterator { method SinglyLinkedListIterator (line 457) | SinglyLinkedListIterator() { method hasNext (line 461) | @Override method next (line 466) | @Override FILE: src/main/java/com/thealgorithms/datastructures/lists/SinglyLinkedListNode.java class SinglyLinkedListNode (line 7) | class SinglyLinkedListNode { method SinglyLinkedListNode (line 12) | SinglyLinkedListNode() { method SinglyLinkedListNode (line 20) | SinglyLinkedListNode(int value) { method SinglyLinkedListNode (line 30) | SinglyLinkedListNode(int value, SinglyLinkedListNode next) { FILE: src/main/java/com/thealgorithms/datastructures/lists/SkipList.java class SkipList (line 32) | @SuppressWarnings({"rawtypes", "unchecked"}) method SkipList (line 59) | public SkipList() { method SkipList (line 63) | public SkipList(int expectedCapacity, HeightStrategy heightStrategy) { method add (line 70) | public void add(E e) { method get (line 99) | public E get(int index) { method remove (line 109) | public void remove(E e) { method contains (line 145) | public boolean contains(E e) { method size (line 163) | public int size() { method toString (line 179) | @Override class Node (line 223) | private static class Node { method Node (line 230) | @SuppressWarnings("unchecked") method next (line 240) | public Node next(int layer) { method setNext (line 245) | public void setNext(int layer, Node node) { method setPrevious (line 249) | public void setPrevious(int layer, Node node) { method previous (line 253) | public Node previous(int layer) { method getValue (line 258) | public E getValue() { method checkLayer (line 262) | private void checkLayer(int layer) { type HeightStrategy (line 274) | public interface HeightStrategy { method height (line 275) | int height(int expectedSize); method nodeHeight (line 276) | int nodeHeight(int heightCap); class BernoulliHeightStrategy (line 290) | public static class BernoulliHeightStrategy implements HeightStrategy { method BernoulliHeightStrategy (line 297) | public BernoulliHeightStrategy() { method BernoulliHeightStrategy (line 301) | public BernoulliHeightStrategy(double probability) { method height (line 308) | @Override method nodeHeight (line 317) | @Override FILE: src/main/java/com/thealgorithms/datastructures/lists/SortedLinkedList.java class SortedLinkedList (line 27) | public class SortedLinkedList { method SortedLinkedList (line 34) | public SortedLinkedList() { method insert (line 44) | public void insert(int value) { method delete (line 74) | public boolean delete(int value) { method search (line 107) | public boolean search(int value) { method isEmpty (line 123) | public boolean isEmpty() { method toString (line 132) | @Override class Node (line 150) | public final class Node { method Node (line 154) | public Node(int value) { FILE: src/main/java/com/thealgorithms/datastructures/lists/TortoiseHareAlgo.java class TortoiseHareAlgo (line 3) | public class TortoiseHareAlgo { class Node (line 4) | static final class Node { method Node (line 8) | private Node(E value, Node next) { method TortoiseHareAlgo (line 16) | public TortoiseHareAlgo() { method append (line 20) | public void append(E value) { method getMiddle (line 33) | public E getMiddle() { method toString (line 49) | @Override FILE: src/main/java/com/thealgorithms/datastructures/queues/CircularQueue.java class CircularQueue (line 25) | public class CircularQueue { method CircularQueue (line 38) | @SuppressWarnings("unchecked") method isEmpty (line 55) | public boolean isEmpty() { method isFull (line 64) | public boolean isFull() { method enQueue (line 74) | public void enQueue(T value) { method deQueue (line 92) | public T deQueue() { method peek (line 113) | public T peek() { method deleteQueue (line 123) | public void deleteQueue() { method size (line 135) | public int size() { FILE: src/main/java/com/thealgorithms/datastructures/queues/Deque.java class Deque (line 14) | public class Deque { class DequeNode (line 19) | private static class DequeNode { method DequeNode (line 24) | DequeNode(S val) { method addFirst (line 38) | public void addFirst(T val) { method addLast (line 58) | public void addLast(T val) { method pollFirst (line 77) | public T pollFirst() { method pollLast (line 100) | public T pollLast() { method peekFirst (line 122) | public T peekFirst() { method peekLast (line 131) | public T peekLast() { method size (line 140) | public int size() { method isEmpty (line 149) | public boolean isEmpty() { method toString (line 161) | @Override method main (line 176) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/datastructures/queues/GenericArrayListQueue.java class GenericArrayListQueue (line 17) | public class GenericArrayListQueue { method isEmpty (line 29) | public boolean isEmpty() { method peek (line 38) | public T peek() { method add (line 48) | public boolean add(T element) { method poll (line 57) | public T poll() { FILE: src/main/java/com/thealgorithms/datastructures/queues/LinkedQueue.java class LinkedQueue (line 6) | public class LinkedQueue implements Iterable { class Node (line 11) | private static class Node { method Node (line 15) | Node(T data) { method LinkedQueue (line 28) | public LinkedQueue() { method isEmpty (line 39) | public boolean isEmpty() { method enqueue (line 49) | public void enqueue(T data) { method dequeue (line 71) | public T dequeue() { method peekFront (line 93) | public T peekFront() { method peekRear (line 106) | public T peekRear() { method peek (line 120) | public T peek(int pos) { method iterator (line 137) | @Override method size (line 165) | public int size() { method clear (line 172) | public void clear() { method toString (line 183) | @Override FILE: src/main/java/com/thealgorithms/datastructures/queues/PriorityQueues.java class PriorityQueue (line 14) | class PriorityQueue { method PriorityQueue (line 33) | PriorityQueue() { method PriorityQueue (line 53) | PriorityQueue(int size) { method swim (line 66) | private void swim(int pos) { method sink (line 85) | private void sink(int pos) { method insert (line 111) | public void insert(int value) { method remove (line 126) | public int remove() { method peek (line 149) | public int peek() { method isEmpty (line 158) | public boolean isEmpty() { method isFull (line 167) | public boolean isFull() { method getSize (line 176) | public int getSize() { FILE: src/main/java/com/thealgorithms/datastructures/queues/Queue.java class Queue (line 10) | public final class Queue { method Queue (line 23) | public Queue() { method Queue (line 33) | public Queue(int capacity) { method insert (line 50) | public boolean insert(T element) { method remove (line 66) | @SuppressWarnings("unchecked") method peekFront (line 84) | @SuppressWarnings("unchecked") method peekRear (line 98) | @SuppressWarnings("unchecked") method isEmpty (line 111) | public boolean isEmpty() { method isFull (line 120) | public boolean isFull() { method getSize (line 129) | public int getSize() { method toString (line 138) | @Override FILE: src/main/java/com/thealgorithms/datastructures/queues/QueueByTwoStacks.java class QueueByTwoStacks (line 14) | @SuppressWarnings("unchecked") method QueueByTwoStacks (line 25) | public QueueByTwoStacks() { method put (line 36) | public void put(T item) { method get (line 49) | public T get() { method size (line 67) | public int size() { method toString (line 80) | @Override FILE: src/main/java/com/thealgorithms/datastructures/queues/ReverseQueueRecursion.java class ReverseQueueRecursion (line 8) | public final class ReverseQueueRecursion { method ReverseQueueRecursion (line 9) | private ReverseQueueRecursion() { method reverseQueue (line 19) | public static void reverseQueue(final Queue queue) { FILE: src/main/java/com/thealgorithms/datastructures/queues/SlidingWindowMaximum.java class SlidingWindowMaximum (line 16) | public final class SlidingWindowMaximum { method SlidingWindowMaximum (line 17) | private SlidingWindowMaximum() { method maxSlidingWindow (line 33) | public static int[] maxSlidingWindow(int[] nums, int k) { FILE: src/main/java/com/thealgorithms/datastructures/queues/TokenBucket.java class TokenBucket (line 15) | public final class TokenBucket { method TokenBucket (line 27) | public TokenBucket(int maxTokens, int refillRate) { method allowRequest (line 41) | public synchronized boolean allowRequest() { method refillTokens (line 55) | private void refillTokens() { FILE: src/main/java/com/thealgorithms/datastructures/stacks/NodeStack.java class NodeStack (line 14) | public class NodeStack { class Node (line 19) | private class Node { method Node (line 23) | Node(Item data) { method NodeStack (line 35) | public NodeStack() { method push (line 45) | public void push(Item item) { method pop (line 58) | public Item pop() { method peek (line 74) | public Item peek() { method isEmpty (line 86) | public boolean isEmpty() { method size (line 95) | public int size() { FILE: src/main/java/com/thealgorithms/datastructures/stacks/ReverseStack.java class ReverseStack (line 26) | public final class ReverseStack { method ReverseStack (line 27) | private ReverseStack() { method reverseStack (line 40) | public static void reverseStack(Stack stack) { method insertAtBottom (line 67) | private static void insertAtBottom(Stack stack, int element) { FILE: src/main/java/com/thealgorithms/datastructures/stacks/Stack.java type Stack (line 8) | public interface Stack { method push (line 15) | void push(T value); method pop (line 23) | T pop(); method peek (line 31) | T peek(); method isEmpty (line 38) | boolean isEmpty(); method size (line 45) | int size(); method makeEmpty (line 50) | void makeEmpty(); FILE: src/main/java/com/thealgorithms/datastructures/stacks/StackArray.java class StackArray (line 14) | public class StackArray implements Stack { method StackArray (line 25) | @SuppressWarnings("unchecked") method StackArray (line 36) | @SuppressWarnings("unchecked") method push (line 51) | @Override method pop (line 66) | @Override method peek (line 84) | @Override method resize (line 97) | private void resize(int newSize) { method isFull (line 109) | public boolean isFull() { method isEmpty (line 118) | @Override method makeEmpty (line 127) | @Override method size (line 137) | @Override method toString (line 147) | @Override FILE: src/main/java/com/thealgorithms/datastructures/stacks/StackArrayList.java class StackArrayList (line 15) | public class StackArrayList implements Stack { method StackArrayList (line 22) | public StackArrayList() { method push (line 31) | @Override method pop (line 42) | @Override method peek (line 56) | @Override method isEmpty (line 69) | @Override method makeEmpty (line 77) | @Override method size (line 87) | @Override FILE: src/main/java/com/thealgorithms/datastructures/stacks/StackOfLinkedList.java class StackOfLinkedList (line 13) | final class StackOfLinkedList { method StackOfLinkedList (line 14) | private StackOfLinkedList() { class Node (line 19) | class Node { method Node (line 23) | Node(int data) { class LinkedListStack (line 41) | class LinkedListStack { method LinkedListStack (line 49) | LinkedListStack() { method push (line 60) | public boolean push(int x) { method pop (line 74) | public int pop() { method peek (line 92) | public int peek() { method toString (line 99) | @Override method isEmpty (line 115) | public boolean isEmpty() { method getSize (line 124) | public int getSize() { method makeEmpty (line 131) | public void makeEmpty() { FILE: src/main/java/com/thealgorithms/datastructures/trees/AVLSimple.java class AVLSimple (line 29) | public class AVLSimple { class Node (line 31) | private class Node { method Node (line 38) | Node(int data) { method insert (line 46) | public void insert(int data) { method insert (line 50) | private Node insert(Node node, int item) { method display (line 84) | public void display() { method display (line 89) | private void display(Node node) { method height (line 111) | private int height(Node node) { method bf (line 118) | private int bf(Node node) { method rightRotate (line 125) | private Node rightRotate(Node c) { method leftRotate (line 136) | private Node leftRotate(Node c) { FILE: src/main/java/com/thealgorithms/datastructures/trees/AVLTree.java class AVLTree (line 12) | public class AVLTree { class Node (line 16) | private static class Node { method Node (line 24) | Node(int k, Node p) { method getBalance (line 29) | public Integer getBalance() { method insert (line 40) | public boolean insert(int key) { method delete (line 74) | public void delete(int delKey) { method delete (line 92) | private void delete(Node node) { method returnBalance (line 131) | public List returnBalance() { method returnBalance (line 137) | private void returnBalance(Node n, List balances) { method search (line 151) | public boolean search(int key) { method searchHelper (line 156) | private Node searchHelper(Node root, int key) { method rebalance (line 167) | private void rebalance(Node n) { method rotateLeft (line 190) | private Node rotateLeft(Node a) { method rotateRight (line 215) | private Node rotateRight(Node a) { method rotateLeftThenRight (line 240) | private Node rotateLeftThenRight(Node n) { method rotateRightThenLeft (line 245) | private Node rotateRightThenLeft(Node n) { method height (line 250) | private int height(Node n) { method setBalance (line 257) | private void setBalance(Node... nodes) { method reheight (line 264) | private void reheight(Node node) { FILE: src/main/java/com/thealgorithms/datastructures/trees/BSTFromSortedArray.java class BSTFromSortedArray (line 12) | public final class BSTFromSortedArray { method BSTFromSortedArray (line 13) | private BSTFromSortedArray() { method createBST (line 15) | public static Node createBST(int[] array) { method createBST (line 22) | private static Node createBST(int[] array, int startIdx, int endIdx) { FILE: src/main/java/com/thealgorithms/datastructures/trees/BSTIterative.java class BSTIterative (line 19) | public class BSTIterative { method BSTIterative (line 29) | BSTIterative() { method getRoot (line 33) | public Node getRoot() { method add (line 43) | public void add(int data) { method remove (line 91) | public void remove(int data) { method find (line 172) | public boolean find(int data) { FILE: src/main/java/com/thealgorithms/datastructures/trees/BSTRecursive.java class BSTRecursive (line 22) | public class BSTRecursive { method BSTRecursive (line 32) | BSTRecursive() { method getRoot (line 36) | public Node getRoot() { method delete (line 47) | private Node delete(Node node, int data) { method insert (line 86) | private Node insert(Node node, int data) { method search (line 104) | private boolean search(Node node, int data) { method add (line 122) | public void add(int data) { method remove (line 131) | public void remove(int data) { method find (line 140) | public boolean find(int data) { FILE: src/main/java/com/thealgorithms/datastructures/trees/BSTRecursiveGeneric.java class BSTRecursiveGeneric (line 18) | public class BSTRecursiveGeneric> { method BSTRecursiveGeneric (line 28) | public BSTRecursiveGeneric() { method prettyDisplay (line 35) | public void prettyDisplay() { method prettyDisplay (line 39) | private void prettyDisplay(Node node, int level) { method main (line 58) | public static void main(String[] args) { method delete (line 135) | private Node delete(Node node, T data) { method insert (line 174) | private Node insert(Node node, T data) { method preOrder (line 190) | private void preOrder(Node node) { method postOrder (line 208) | private void postOrder(Node node) { method inOrder (line 226) | private void inOrder(Node node) { method inOrderSort (line 246) | private void inOrderSort(Node node, List sortedList) { method search (line 266) | private boolean search(Node node, T data) { method add (line 284) | public void add(T data) { method remove (line 293) | public void remove(T data) { method inorder (line 300) | public void inorder() { method inorderSort (line 310) | public List inorderSort() { method postorder (line 319) | public void postorder() { method preorder (line 328) | public void preorder() { method find (line 339) | public boolean find(T data) { class Node (line 351) | private static class Node { method Node (line 360) | Node(T d) { FILE: src/main/java/com/thealgorithms/datastructures/trees/BTree.java class BTree (line 15) | public class BTree { class BTreeNode (line 16) | static class BTreeNode { method BTreeNode (line 23) | BTreeNode(int t, boolean leaf) { method traverse (line 31) | void traverse(ArrayList result) { method search (line 43) | BTreeNode search(int key) { method insertNonFull (line 57) | void insertNonFull(int key) { method splitChild (line 80) | void splitChild(int i, BTreeNode y) { method remove (line 102) | void remove(int key) { method findKey (line 129) | private int findKey(int key) { method removeFromLeaf (line 137) | private void removeFromLeaf(int idx) { method removeFromNonLeaf (line 144) | private void removeFromNonLeaf(int idx) { method getPredecessor (line 160) | private int getPredecessor(int idx) { method getSuccessor (line 168) | private int getSuccessor(int idx) { method fill (line 176) | private void fill(int idx) { method borrowFromPrev (line 190) | private void borrowFromPrev(int idx) { method borrowFromNext (line 216) | private void borrowFromNext(int idx) { method merge (line 242) | private void merge(int idx) { method BTree (line 274) | public BTree(int t) { method traverse (line 279) | public void traverse(ArrayList result) { method search (line 285) | public boolean search(int key) { method insert (line 289) | public void insert(int key) { method delete (line 314) | public void delete(int key) { FILE: src/main/java/com/thealgorithms/datastructures/trees/BinaryTree.java class BinaryTree (line 17) | public class BinaryTree { class Node (line 26) | static class Node { method Node (line 50) | Node(int value) { method BinaryTree (line 66) | public BinaryTree() { method BinaryTree (line 73) | public BinaryTree(Node root) { method find (line 83) | public Node find(int key) { method put (line 108) | public void put(int value) { method remove (line 133) | public boolean remove(int value) { method findSuccessor (line 234) | public Node findSuccessor(Node n) { method getRoot (line 252) | public Node getRoot() { method inOrder (line 262) | public void inOrder(Node localRoot) { method preOrder (line 275) | public void preOrder(Node localRoot) { method postOrder (line 288) | public void postOrder(Node localRoot) { method bfs (line 303) | public void bfs(Node localRoot) { FILE: src/main/java/com/thealgorithms/datastructures/trees/BinaryTreeToString.java class BinaryTreeToString (line 47) | public class BinaryTreeToString { method tree2str (line 59) | public String tree2str(BinaryTree.Node root) { method dfs (line 78) | private void dfs(BinaryTree.Node node) { FILE: src/main/java/com/thealgorithms/datastructures/trees/BoundaryTraversal.java class BoundaryTraversal (line 25) | public final class BoundaryTraversal { method BoundaryTraversal (line 26) | private BoundaryTraversal() { method boundaryTraversal (line 30) | public static List boundaryTraversal(BinaryTree.Node root) { method addLeftBoundary (line 54) | private static void addLeftBoundary(BinaryTree.Node node, List resu... method addRightBoundary (line 90) | private static void addRightBoundary(BinaryTree.Node node, List iterativeBoundaryTraversal(BinaryTree.Node... FILE: src/main/java/com/thealgorithms/datastructures/trees/CeilInBinarySearchTree.java class CeilInBinarySearchTree (line 43) | public final class CeilInBinarySearchTree { method CeilInBinarySearchTree (line 44) | private CeilInBinarySearchTree() { method getCeil (line 47) | public static Node getCeil(Node root, int key) { FILE: src/main/java/com/thealgorithms/datastructures/trees/CentroidDecomposition.java class CentroidDecomposition (line 26) | public final class CentroidDecomposition { method CentroidDecomposition (line 28) | private CentroidDecomposition() { class CentroidTree (line 34) | public static final class CentroidTree { method CentroidTree (line 48) | public CentroidTree(List> adj) { method decompose (line 71) | private int decompose(int u, int p) { method getSubtreeSize (line 95) | private int getSubtreeSize(int u, int p) { method findCentroid (line 114) | private int findCentroid(int u, int p, int totalSize) { method getParent (line 129) | public int getParent(int node) { method getRoot (line 141) | public int getRoot() { method size (line 150) | public int size() { method toString (line 160) | @Override method buildFromEdges (line 184) | public static CentroidTree buildFromEdges(int n, int[][] edges) { FILE: src/main/java/com/thealgorithms/datastructures/trees/CheckBinaryTreeIsValidBST.java class CheckBinaryTreeIsValidBST (line 11) | public final class CheckBinaryTreeIsValidBST { method CheckBinaryTreeIsValidBST (line 12) | private CheckBinaryTreeIsValidBST() { method isBST (line 14) | public static boolean isBST(BinaryTree.Node root) { method isBSTUtil (line 18) | private static boolean isBSTUtil(BinaryTree.Node node, int min, int ma... FILE: src/main/java/com/thealgorithms/datastructures/trees/CheckIfBinaryTreeBalanced.java class CheckIfBinaryTreeBalanced (line 17) | public final class CheckIfBinaryTreeBalanced { method CheckIfBinaryTreeBalanced (line 18) | private CheckIfBinaryTreeBalanced() { method isBalancedRecursive (line 25) | public static boolean isBalancedRecursive(BinaryTree.Node root) { method isBalancedRecursive (line 48) | private static int isBalancedRecursive(BinaryTree.Node node, int depth... method isBalancedIterative (line 74) | public static boolean isBalancedIterative(BinaryTree.Node root) { FILE: src/main/java/com/thealgorithms/datastructures/trees/CheckTreeIsSymmetric.java class CheckTreeIsSymmetric (line 33) | public final class CheckTreeIsSymmetric { method CheckTreeIsSymmetric (line 34) | private CheckTreeIsSymmetric() { method isSymmetric (line 37) | public static boolean isSymmetric(Node root) { method isSymmetric (line 44) | private static boolean isSymmetric(Node leftSubtreeRoot, Node rightSub... method isInvalidSubtree (line 56) | private static boolean isInvalidSubtree(Node leftSubtreeRoot, Node rig... FILE: src/main/java/com/thealgorithms/datastructures/trees/CreateBinaryTreeFromInorderPreorder.java class CreateBinaryTreeFromInorderPreorder (line 20) | public final class CreateBinaryTreeFromInorderPreorder { method CreateBinaryTreeFromInorderPreorder (line 21) | private CreateBinaryTreeFromInorderPreorder() { method createTree (line 23) | public static Node createTree(final Integer[] preorder, final Integer[... method createTreeOptimized (line 30) | public static Node createTreeOptimized(final Integer[] preorder, final... method createTree (line 41) | private static Node createTree(final Integer[] preorder, final Integer... method createTreeOptimized (line 58) | private static Node createTreeOptimized(final Integer[] preorder, fina... FILE: src/main/java/com/thealgorithms/datastructures/trees/FenwickTree.java class FenwickTree (line 3) | public class FenwickTree { method FenwickTree (line 9) | public FenwickTree(int n) { method update (line 15) | public void update(int i, int val) { method query (line 25) | public int query(int i) { FILE: src/main/java/com/thealgorithms/datastructures/trees/GenericTree.java class GenericTree (line 17) | public class GenericTree { class Node (line 19) | private static final class Node { method GenericTree (line 27) | public GenericTree() { // Constructor method createTreeG (line 32) | private Node createTreeG(Node node, int childIndex, Scanner scanner) { method display (line 54) | public void display() { // Helper function method display1 (line 58) | private void display1(Node parent) { method size2call (line 75) | public int size2call() { method size2 (line 79) | public int size2(Node roott) { method maxcall (line 92) | public int maxcall() { method max (line 97) | private int max(Node roott, int maxi) { method heightcall (line 113) | public int heightcall() { method height (line 117) | private int height(Node node) { method findcall (line 134) | public boolean findcall(int info) { method find (line 138) | private boolean find(Node node, int info) { method depthcaller (line 155) | public void depthcaller(int dep) { method depth (line 159) | public void depth(Node node, int dep) { method preordercall (line 172) | public void preordercall() { method preorder (line 177) | private void preorder(Node node) { method postordercall (line 187) | public void postordercall() { method postorder (line 192) | private void postorder(Node node) { method levelorder (line 202) | public void levelorder() { method removeleavescall (line 220) | public void removeleavescall() { method removeleaves (line 224) | private void removeleaves(Node node) { FILE: src/main/java/com/thealgorithms/datastructures/trees/InorderTraversal.java class InorderTraversal (line 28) | public final class InorderTraversal { method InorderTraversal (line 29) | private InorderTraversal() { method recursiveInorder (line 31) | public static List recursiveInorder(BinaryTree.Node root) { method iterativeInorder (line 37) | public static List iterativeInorder(BinaryTree.Node root) { method recursiveInorder (line 56) | private static void recursiveInorder(BinaryTree.Node root, List search(Point point) { method search (line 297) | public Optional search(Node root, Point point) { method findMin (line 314) | public Point findMin(int axis) { method findMin (line 326) | public Node findMin(Node root, int axis) { method findMax (line 350) | public Point findMax(int axis) { method findMax (line 362) | public Node findMax(Node root, int axis) { method delete (line 384) | public void delete(Point point) { method delete (line 397) | private Node delete(Node root, Node node) { method findNearest (line 427) | public Point findNearest(Point point) { method findNearest (line 438) | private Node findNearest(Node root, Point point, Node nearest) { FILE: src/main/java/com/thealgorithms/datastructures/trees/LCA.java class LCA (line 6) | public final class LCA { method LCA (line 7) | private LCA() { method main (line 12) | public static void main(String[] args) { method dfs (line 61) | private static void dfs(ArrayList> adj, int s, int ... method getLCA (line 80) | private static int getLCA(int v1, int v2, int[] depth, int[] parent) { FILE: src/main/java/com/thealgorithms/datastructures/trees/LazySegmentTree.java class LazySegmentTree (line 3) | public class LazySegmentTree { class Node (line 11) | static class Node { method Node (line 20) | Node(int start, int end, int value) { method applyUpdate (line 34) | public void applyUpdate(int diff) { method shift (line 42) | public void shift() { method merge (line 66) | static Node merge(Node left, Node right) { method getValue (line 79) | public int getValue() { method getLeft (line 83) | public Node getLeft() { method getRight (line 87) | public Node getRight() { method LazySegmentTree (line 99) | public LazySegmentTree(int[] array) { method buildTree (line 111) | private Node buildTree(int[] array, int start, int end) { method updateRange (line 129) | private void updateRange(int left, int right, int diff, Node curr) { method getRange (line 151) | private Node getRange(int left, int right, Node curr) { method getRange (line 162) | public int getRange(int left, int right) { method updateRange (line 167) | public void updateRange(int left, int right, int diff) { method getRoot (line 171) | public Node getRoot() { FILE: src/main/java/com/thealgorithms/datastructures/trees/LevelOrderTraversal.java class LevelOrderTraversal (line 8) | public final class LevelOrderTraversal { method LevelOrderTraversal (line 9) | private LevelOrderTraversal() { method traverse (line 12) | public static List> traverse(BinaryTree.Node root) { method printGivenLevel (line 42) | public static void printGivenLevel(BinaryTree.Node root, int level) { FILE: src/main/java/com/thealgorithms/datastructures/trees/PostOrderTraversal.java class PostOrderTraversal (line 29) | public final class PostOrderTraversal { method PostOrderTraversal (line 30) | private PostOrderTraversal() { method recursivePostOrder (line 32) | public static List recursivePostOrder(BinaryTree.Node root) { method iterativePostOrder (line 38) | public static List iterativePostOrder(BinaryTree.Node root) { method recursivePostOrder (line 60) | private static void recursivePostOrder(BinaryTree.Node root, List recursivePreOrder(BinaryTree.Node root) { method iterativePreOrder (line 37) | public static List iterativePreOrder(BinaryTree.Node root) { method recursivePreOrder (line 59) | private static void recursivePreOrder(BinaryTree.Node root, List query(BoundingBox otherBoundingBox) { FILE: src/main/java/com/thealgorithms/datastructures/trees/RedBlackBST.java class RedBlackBST (line 8) | public class RedBlackBST { class Node (line 13) | private class Node { method Node (line 21) | Node(int key) { method printTree (line 29) | public void printTree(Node node) { method printTreepre (line 38) | public void printTreepre(Node node) { method findNode (line 47) | private Node findNode(Node findNode, Node node) { method insert (line 65) | private void insert(Node node) { method fixTree (line 96) | private void fixTree(Node node) { method rotateLeft (line 137) | void rotateLeft(Node node) { method rotateRight (line 162) | void rotateRight(Node node) { method transplant (line 188) | void transplant(Node target, Node with) { method treeMinimum (line 199) | Node treeMinimum(Node subTreeRoot) { method delete (line 206) | boolean delete(Node z) { method deleteFixup (line 243) | void deleteFixup(Node x) { method insertDemo (line 300) | public void insertDemo() { method deleteDemo (line 319) | public void deleteDemo() { FILE: src/main/java/com/thealgorithms/datastructures/trees/SameTreesCheck.java class SameTreesCheck (line 35) | public final class SameTreesCheck { method SameTreesCheck (line 36) | private SameTreesCheck() { method check (line 38) | public static boolean check(BinaryTree.Node p, BinaryTree.Node q) { method equalNodes (line 80) | private static boolean equalNodes(BinaryTree.Node p, BinaryTree.Node q) { FILE: src/main/java/com/thealgorithms/datastructures/trees/SegmentTree.java class SegmentTree (line 3) | public class SegmentTree { method SegmentTree (line 10) | public SegmentTree(int n, int[] arr) { method constructTree (line 22) | public final int constructTree(int[] arr, int start, int end, int inde... method updateTree (line 35) | private void updateTree(int start, int end, int index, int diff, int s... method update (line 49) | public void update(int index, int value) { method getSumTree (line 61) | private int getSumTree(int start, int end, int qStart, int qEnd, int s... method getSum (line 75) | public int getSum(int start, int end) { FILE: src/main/java/com/thealgorithms/datastructures/trees/SplayTree.java class SplayTree (line 27) | public class SplayTree { method isEmpty (line 39) | public boolean isEmpty() { method insert (line 48) | public void insert(final int key) { method search (line 59) | public boolean search(int key) { method delete (line 70) | public void delete(final int key) { method traverse (line 96) | public List traverse(TreeTraversal traversal) { method findMax (line 113) | private Node findMax(Node root) { method rotateRight (line 134) | private Node rotateRight(Node x) { method rotateLeft (line 155) | private Node rotateLeft(Node x) { method splay (line 194) | private Node splay(Node root, final int key) { method insertRec (line 232) | private Node insertRec(Node root, final int key) { class EmptyTreeException (line 248) | public static class EmptyTreeException extends RuntimeException { method EmptyTreeException (line 251) | public EmptyTreeException(String message) { class DuplicateKeyException (line 256) | public static class DuplicateKeyException extends RuntimeException { method DuplicateKeyException (line 259) | public DuplicateKeyException(String message) { class Node (line 264) | private static class Node { method Node (line 269) | Node(int key) { type TreeTraversal (line 276) | public interface TreeTraversal { method traverse (line 283) | void traverse(Node root, List result); class InOrderTraversal (line 286) | private static final class InOrderTraversal implements TreeTraversal { method InOrderTraversal (line 287) | private InOrderTraversal() { method traverse (line 290) | public void traverse(Node root, List result) { class PreOrderTraversal (line 299) | private static final class PreOrderTraversal implements TreeTraversal { method PreOrderTraversal (line 300) | private PreOrderTraversal() { method traverse (line 303) | public void traverse(Node root, List result) { class PostOrderTraversal (line 312) | private static final class PostOrderTraversal implements TreeTraversal { method PostOrderTraversal (line 313) | private PostOrderTraversal() { method traverse (line 316) | public void traverse(Node root, List result) { FILE: src/main/java/com/thealgorithms/datastructures/trees/ThreadedBinaryTree.java class ThreadedBinaryTree (line 23) | public final class ThreadedBinaryTree { class Node (line 27) | private static final class Node { method Node (line 34) | Node(int value) { method ThreadedBinaryTree (line 43) | public ThreadedBinaryTree() { method insert (line 53) | public void insert(int value) { method inorderTraversal (line 107) | public List inorderTraversal() { method isEmpty (line 142) | public boolean isEmpty() { FILE: src/main/java/com/thealgorithms/datastructures/trees/Treap.java class Treap (line 13) | public class Treap { class TreapNode (line 15) | public static class TreapNode { method TreapNode (line 37) | public TreapNode(int valueParam, int priorityParam) { method updateSize (line 48) | private void updateSize() { method Treap (line 72) | public Treap() { method merge (line 83) | private TreapNode merge(TreapNode left, TreapNode right) { method split (line 111) | private TreapNode[] split(TreapNode node, int key) { method insert (line 139) | public TreapNode insert(int value) { method delete (line 166) | public TreapNode delete(int value) { method deleteNode (line 171) | private TreapNode deleteNode(TreapNode root, int value) { method inOrder (line 193) | public void inOrder() { method printInorder (line 199) | private void printInorder(TreapNode root) { method preOrder (line 211) | public void preOrder() { method printPreOrder (line 217) | private void printPreOrder(TreapNode root) { method postOrder (line 229) | public void postOrder() { method printPostOrder (line 235) | private void printPostOrder(TreapNode root) { method search (line 251) | public TreapNode search(int value) { method searchVal (line 255) | private TreapNode searchVal(TreapNode root, int value) { method lowerBound (line 275) | public TreapNode lowerBound(int value) { method upperBound (line 297) | public TreapNode upperBound(int value) { method size (line 316) | public int size() { method isEmpty (line 326) | public boolean isEmpty() { method getRoot (line 333) | public TreapNode getRoot() { method getLeft (line 340) | public TreapNode getLeft(TreapNode node) { method getRight (line 347) | public TreapNode getRight(TreapNode node) { method toString (line 354) | public String toString(TreapNode node) { FILE: src/main/java/com/thealgorithms/datastructures/trees/TreeRandomNode.java class TreeRandomNode (line 27) | public class TreeRandomNode { class Node (line 29) | private final class Node { method TreeRandomNode (line 41) | TreeRandomNode() { method inOrder (line 46) | static void inOrder(Node node) { method getRandom (line 59) | public void getRandom(Node val) { FILE: src/main/java/com/thealgorithms/datastructures/trees/Trie.java class TrieNode (line 10) | class TrieNode { method TrieNode (line 19) | TrieNode(char value) { class Trie (line 43) | public class Trie { method Trie (line 52) | public Trie() { method insert (line 64) | public void insert(String word) { method search (line 89) | public boolean search(String word) { method delete (line 114) | public boolean delete(String word) { method countWords (line 140) | public int countWords() { method countWords (line 144) | private int countWords(TrieNode node) { method startsWithPrefix (line 167) | public boolean startsWithPrefix(String prefix) { method countWordsWithPrefix (line 188) | public int countWordsWithPrefix(String prefix) { FILE: src/main/java/com/thealgorithms/datastructures/trees/VerticalOrderTraversal.java class VerticalOrderTraversal (line 23) | public final class VerticalOrderTraversal { method VerticalOrderTraversal (line 24) | private VerticalOrderTraversal() { method verticalTraversal (line 29) | public static ArrayList verticalTraversal(BinaryTree.Node roo... FILE: src/main/java/com/thealgorithms/datastructures/trees/ZigzagTraversal.java class ZigzagTraversal (line 37) | public final class ZigzagTraversal { method ZigzagTraversal (line 38) | private ZigzagTraversal() { method traverse (line 40) | public static List> traverse(BinaryTree.Node root) { FILE: src/main/java/com/thealgorithms/datastructures/trees/nearestRightKey.java class NearestRightKey (line 6) | final class NearestRightKey { method NearestRightKey (line 7) | private NearestRightKey() { method main (line 10) | public static void main(String[] args) { method buildTree (line 20) | public static NRKTree buildTree() { method nearestRightKey (line 32) | public static int nearestRightKey(NRKTree root, int x0) { class NRKTree (line 52) | class NRKTree { method NRKTree (line 58) | NRKTree(int x) { method NRKTree (line 64) | NRKTree(NRKTree right, NRKTree left, int x) { method insertKey (line 70) | public NRKTree insertKey(NRKTree current, int value) { FILE: src/main/java/com/thealgorithms/devutils/entities/ProcessDetails.java class ProcessDetails (line 3) | public class ProcessDetails { method ProcessDetails (line 11) | public ProcessDetails(final String processId, final int arrivalTime, f... method ProcessDetails (line 18) | public ProcessDetails(final String processId, final int arrivalTime, f... method getProcessId (line 24) | public String getProcessId() { method getArrivalTime (line 28) | public int getArrivalTime() { method getBurstTime (line 32) | public int getBurstTime() { method getWaitingTime (line 36) | public int getWaitingTime() { method getTurnAroundTimeTime (line 40) | public int getTurnAroundTimeTime() { method getPriority (line 44) | public int getPriority() { method setProcessId (line 48) | public void setProcessId(final String processId) { method setArrivalTime (line 52) | public void setArrivalTime(final int arrivalTime) { method setBurstTime (line 56) | public void setBurstTime(final int burstTime) { method setWaitingTime (line 60) | public void setWaitingTime(final int waitingTime) { method setTurnAroundTimeTime (line 64) | public void setTurnAroundTimeTime(final int turnAroundTime) { FILE: src/main/java/com/thealgorithms/devutils/nodes/LargeTreeNode.java class LargeTreeNode (line 13) | public class LargeTreeNode extends TreeNode { method LargeTreeNode (line 23) | public LargeTreeNode() { method LargeTreeNode (line 33) | public LargeTreeNode(E data) { method LargeTreeNode (line 44) | public LargeTreeNode(E data, LargeTreeNode parentNode) { method LargeTreeNode (line 56) | public LargeTreeNode(E data, LargeTreeNode parentNode, Collection> getChildNodes() { method setChildNodes (line 74) | public void setChildNodes(Collection> childNodes) { FILE: src/main/java/com/thealgorithms/devutils/nodes/Node.java class Node (line 13) | public abstract class Node { method Node (line 23) | public Node() { method Node (line 31) | public Node(E data) { method getData (line 35) | public E getData() { method setData (line 39) | public void setData(E data) { FILE: src/main/java/com/thealgorithms/devutils/nodes/SimpleNode.java class SimpleNode (line 10) | public class SimpleNode extends Node { method SimpleNode (line 20) | public SimpleNode() { method SimpleNode (line 30) | public SimpleNode(E data) { method SimpleNode (line 40) | public SimpleNode(E data, SimpleNode nextNode) { method hasNext (line 48) | public boolean hasNext() { method getNextNode (line 52) | public SimpleNode getNextNode() { method setNextNode (line 56) | public void setNextNode(SimpleNode nextNode) { FILE: src/main/java/com/thealgorithms/devutils/nodes/SimpleTreeNode.java class SimpleTreeNode (line 11) | public class SimpleTreeNode extends TreeNode { method SimpleTreeNode (line 25) | public SimpleTreeNode() { method SimpleTreeNode (line 35) | public SimpleTreeNode(E data) { method SimpleTreeNode (line 46) | public SimpleTreeNode(E data, SimpleTreeNode parentNode) { method SimpleTreeNode (line 60) | public SimpleTreeNode(E data, SimpleTreeNode parentNode, SimpleTree... method isLeafNode (line 70) | @Override method getLeftNode (line 75) | public SimpleTreeNode getLeftNode() { method setLeftNode (line 79) | public void setLeftNode(SimpleTreeNode leftNode) { method getRightNode (line 83) | public SimpleTreeNode getRightNode() { method setRightNode (line 87) | public void setRightNode(SimpleTreeNode rightNode) { FILE: src/main/java/com/thealgorithms/devutils/nodes/TreeNode.java class TreeNode (line 12) | public abstract class TreeNode extends Node { method TreeNode (line 26) | public TreeNode() { method TreeNode (line 37) | public TreeNode(E data) { method TreeNode (line 48) | public TreeNode(E data, TreeNode parentNode) { method isLeafNode (line 57) | public abstract boolean isLeafNode(); method isRootNode (line 62) | public boolean isRootNode() { method getParent (line 66) | public TreeNode getParent() { method setParent (line 70) | public void setParent(TreeNode parentNode) { method getDepth (line 75) | public int getDepth() { FILE: src/main/java/com/thealgorithms/devutils/searches/MatrixSearchAlgorithm.java type MatrixSearchAlgorithm (line 8) | public interface MatrixSearchAlgorithm { method find (line 15) | > int[] find(T[][] matrix, T key); FILE: src/main/java/com/thealgorithms/devutils/searches/SearchAlgorithm.java type SearchAlgorithm (line 8) | public interface SearchAlgorithm { method find (line 15) | > int find(T[] array, T key); FILE: src/main/java/com/thealgorithms/divideandconquer/BinaryExponentiation.java class BinaryExponentiation (line 15) | public class BinaryExponentiation { method calculatePower (line 18) | public static long calculatePower(long x, long y) { method power (line 30) | long power(long n, long m) { FILE: src/main/java/com/thealgorithms/divideandconquer/ClosestPair.java class ClosestPair (line 7) | public final class ClosestPair { method setMinNum (line 30) | public static void setMinNum(double minNum) { method setSecondCount (line 34) | public static void setSecondCount(int secondCount) { method ClosestPair (line 46) | ClosestPair(int points) { class Location (line 54) | public static class Location { method Location (line 63) | Location(final double xpar, final double ypar) { // Save x, y coordi... method buildLocation (line 69) | public Location buildLocation(double x, double y) { method xPartition (line 81) | public int xPartition(final Location[] a, final int first, final int l... method yPartition (line 108) | public int yPartition(final Location[] a, final int first, final int l... method xQuickSort (line 134) | public void xQuickSort(final Location[] a, final int first, final int ... method yQuickSort (line 149) | public void yQuickSort(final Location[] a, final int first, final int ... method closestPair (line 164) | public double closestPair(final Location[] a, final int indexNum) { method bruteForce (line 250) | public double bruteForce(final Location[] arrayParam) { method main (line 304) | public static void main(final String[] args) { FILE: src/main/java/com/thealgorithms/divideandconquer/CountingInversions.java class CountingInversions (line 23) | public final class CountingInversions { method CountingInversions (line 24) | private CountingInversions() { method countInversions (line 33) | public static int countInversions(int[] arr) { method mergeSortAndCount (line 46) | private static int mergeSortAndCount(int[] arr, int left, int right) { method mergeAndCount (line 71) | private static int mergeAndCount(int[] arr, int left, int mid, int rig... FILE: src/main/java/com/thealgorithms/divideandconquer/MedianOfTwoSortedArrays.java class MedianOfTwoSortedArrays (line 3) | public final class MedianOfTwoSortedArrays { method MedianOfTwoSortedArrays (line 5) | private MedianOfTwoSortedArrays() { method findMedianSortedArrays (line 16) | public static double findMedianSortedArrays(int[] nums1, int[] nums2) { FILE: src/main/java/com/thealgorithms/divideandconquer/SkylineAlgorithm.java class SkylineAlgorithm (line 12) | public class SkylineAlgorithm { method SkylineAlgorithm (line 20) | public SkylineAlgorithm() { method getPoints (line 27) | public ArrayList getPoints() { method produceSubSkyLines (line 47) | public ArrayList produceSubSkyLines(ArrayList list) { method produceFinalSkyLine (line 95) | public ArrayList produceFinalSkyLine(ArrayList left, Arr... class Point (line 128) | public static class Point { method Point (line 140) | public Point(int x, int y) { method getX (line 148) | public int getX() { method getY (line 155) | public int getY() { method dominates (line 167) | public boolean dominates(Point p1) { class XComparator (line 177) | class XComparator implements Comparator { method compare (line 179) | @Override FILE: src/main/java/com/thealgorithms/divideandconquer/StrassenMatrixMultiplication.java class StrassenMatrixMultiplication (line 18) | public class StrassenMatrixMultiplication { method multiply (line 21) | public int[][] multiply(int[][] a, int[][] b) { method sub (line 96) | public int[][] sub(int[][] a, int[][] b) { method add (line 111) | public int[][] add(int[][] a, int[][] b) { method split (line 126) | public void split(int[][] p, int[][] c, int iB, int jB) { method join (line 135) | public void join(int[][] c, int[][] p, int iB, int jB) { FILE: src/main/java/com/thealgorithms/divideandconquer/TilingProblem.java class TilingProblem (line 17) | public final class TilingProblem { method TilingProblem (line 18) | private TilingProblem() { method solveTiling (line 39) | public static int[][] solveTiling(int size, int missingRow, int missin... method fillBoard (line 59) | private static void fillBoard(int size, int row, int col, int missingR... FILE: src/main/java/com/thealgorithms/dynamicprogramming/Abbreviation.java class Abbreviation (line 15) | public final class Abbreviation { method Abbreviation (line 16) | private Abbreviation() { method abbr (line 31) | public static boolean abbr(String a, String b) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/AllConstruct.java class AllConstruct (line 15) | public final class AllConstruct { method AllConstruct (line 16) | private AllConstruct() { method allConstruct (line 32) | public static List> allConstruct(String target, Iterable<... FILE: src/main/java/com/thealgorithms/dynamicprogramming/AssignmentUsingBitmask.java class AssignmentUsingBitmask (line 14) | public final class AssignmentUsingBitmask { method AssignmentUsingBitmask (line 27) | public AssignmentUsingBitmask(List> taskPerformed, int t... method countWaysUntil (line 57) | private int countWaysUntil(int mask, int taskNo) { method countNoOfWays (line 88) | public int countNoOfWays() { FILE: src/main/java/com/thealgorithms/dynamicprogramming/BoardPath.java class BoardPath (line 3) | public final class BoardPath { method BoardPath (line 4) | private BoardPath() { method bpR (line 14) | public static int bpR(int start, int end) { method bpRS (line 35) | public static int bpRS(int curr, int end, int[] strg) { method bpIS (line 60) | public static int bpIS(int curr, int end, int[] strg) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/BoundaryFill.java class BoundaryFill (line 7) | public final class BoundaryFill { method BoundaryFill (line 8) | private BoundaryFill() { method getPixel (line 18) | public static int getPixel(int[][] image, int xCoordinate, int yCoordi... method putPixel (line 29) | public static void putPixel(int[][] image, int xCoordinate, int yCoord... method boundaryFill (line 42) | public static void boundaryFill(int[][] image, int xCoordinate, int yC... FILE: src/main/java/com/thealgorithms/dynamicprogramming/BruteForceKnapsack.java class BruteForceKnapsack (line 22) | public final class BruteForceKnapsack { method BruteForceKnapsack (line 23) | private BruteForceKnapsack() { method knapSack (line 56) | static int knapSack(int w, int[] wt, int[] val, int n) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/CatalanNumber.java class CatalanNumber (line 12) | public final class CatalanNumber { method CatalanNumber (line 13) | private CatalanNumber() { method findNthCatalan (line 25) | static long findNthCatalan(int n) { method main (line 48) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/ClimbingStairs.java class ClimbingStairs (line 20) | public final class ClimbingStairs { method ClimbingStairs (line 22) | private ClimbingStairs() { method numberOfWays (line 34) | public static int numberOfWays(int n) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/CoinChange.java class CoinChange (line 6) | public final class CoinChange { method CoinChange (line 7) | private CoinChange() { method change (line 18) | public static int change(int[] coins, int amount) { method minimumCoins (line 38) | public static int minimumCoins(int[] coins, int amount) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/CountFriendsPairing.java class CountFriendsPairing (line 12) | public final class CountFriendsPairing { method CountFriendsPairing (line 13) | private CountFriendsPairing() { method countFriendsPairing (line 16) | public static boolean countFriendsPairing(int n, int[] a) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/DamerauLevenshteinDistance.java class DamerauLevenshteinDistance (line 19) | public final class DamerauLevenshteinDistance { method DamerauLevenshteinDistance (line 21) | private DamerauLevenshteinDistance() { method distance (line 33) | public static int distance(String s1, String s2) { method validateInputs (line 54) | private static void validateInputs(String s1, String s2) { method buildCharacterMap (line 71) | private static Map buildCharacterMap(String s1, St... method initializeTable (line 97) | private static int[][] initializeTable(int n, int m) { method fillTable (line 132) | private static void fillTable(String s1, String s2, int[][] dp, Map matri... method matrixChainOrder (line 54) | private static void matrixChainOrder(int size) { class Result (line 79) | public static class Result { method Result (line 90) | public Result(int[][] m, int[][] s) { method getM (line 100) | public int[][] getM() { method getS (line 109) | public int[][] getS() { class Matrix (line 117) | public static class Matrix { method Matrix (line 130) | public Matrix(int count, int col, int row) { method count (line 141) | public int count() { method col (line 150) | public int col() { method row (line 159) | public int row() { FILE: src/main/java/com/thealgorithms/dynamicprogramming/MatrixChainRecursiveTopDownMemoisation.java class MatrixChainRecursiveTopDownMemoisation (line 16) | public final class MatrixChainRecursiveTopDownMemoisation { method MatrixChainRecursiveTopDownMemoisation (line 17) | private MatrixChainRecursiveTopDownMemoisation() { method memoizedMatrixChain (line 29) | static int memoizedMatrixChain(int[] p) { method lookupChain (line 51) | static int lookupChain(int[][] m, int[] p, int i, int j) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/MaximumProductSubarray.java class MaximumProductSubarray (line 17) | public final class MaximumProductSubarray { method MaximumProductSubarray (line 19) | private MaximumProductSubarray() { method maxProduct (line 31) | public static int maxProduct(int[] nums) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/MaximumSumOfNonAdjacentElements.java class MaximumSumOfNonAdjacentElements (line 9) | final class MaximumSumOfNonAdjacentElements { method MaximumSumOfNonAdjacentElements (line 11) | private MaximumSumOfNonAdjacentElements() { method getMaxSumApproach1 (line 21) | public static int getMaxSumApproach1(int[] arr) { method getMaxSumApproach2 (line 60) | public static int getMaxSumApproach2(int[] arr) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/MinimumPathSum.java class MinimumPathSum (line 27) | public final class MinimumPathSum { method MinimumPathSum (line 29) | private MinimumPathSum() { method minimumPathSum (line 32) | public static int minimumPathSum(final int[][] grid) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/MinimumSumPartition.java class MinimumSumPartition (line 22) | public final class MinimumSumPartition { method MinimumSumPartition (line 23) | private MinimumSumPartition() { method throwIfInvalidInput (line 26) | private static void throwIfInvalidInput(final int[] array) { method minimumSumPartition (line 32) | public static int minimumSumPartition(final int[] array) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/NeedlemanWunsch.java class NeedlemanWunsch (line 11) | public final class NeedlemanWunsch { method NeedlemanWunsch (line 13) | private NeedlemanWunsch() { method align (line 27) | public static int align(String s1, String s2, int matchScore, int mism... FILE: src/main/java/com/thealgorithms/dynamicprogramming/NewManShanksPrime.java class NewManShanksPrime (line 24) | public final class NewManShanksPrime { method NewManShanksPrime (line 25) | private NewManShanksPrime() { method nthManShanksPrime (line 37) | public static boolean nthManShanksPrime(int n, int expectedAnswer) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/OptimalJobScheduling.java class OptimalJobScheduling (line 12) | public class OptimalJobScheduling { method OptimalJobScheduling (line 28) | public OptimalJobScheduling(int numberProcesses, int numberMachines, i... method execute (line 39) | public void execute() { method calculateCost (line 47) | private void calculateCost() { method runningCost (line 70) | private int runningCost(int process, int machine) { method findMin (line 95) | private int findMin(int[] costArr) { method showResults (line 111) | private void showResults() { method getCost (line 128) | public int getCost(int process, int machine) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/PalindromicPartitioning.java class PalindromicPartitioning (line 24) | public final class PalindromicPartitioning { method PalindromicPartitioning (line 25) | private PalindromicPartitioning() { method minimalPartitions (line 28) | public static int minimalPartitions(String word) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/PartitionProblem.java class PartitionProblem (line 18) | public final class PartitionProblem { method PartitionProblem (line 19) | private PartitionProblem() { method partition (line 29) | public static boolean partition(int[] nums) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/RegexMatching.java class RegexMatching (line 14) | public final class RegexMatching { method RegexMatching (line 15) | private RegexMatching() { method regexRecursion (line 30) | public static boolean regexRecursion(String src, String pat) { method regexRecursion (line 77) | static boolean regexRecursion(String src, String pat, int svidx, int p... method regexRecursion (line 122) | public static boolean regexRecursion(String src, String pat, int svidx... method regexBU (line 169) | static boolean regexBU(String src, String pat) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/RodCutting.java class RodCutting (line 7) | public final class RodCutting { method RodCutting (line 8) | private RodCutting() { method cutRod (line 21) | public static int cutRod(int[] price, int n) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/ShortestCommonSupersequenceLength.java class ShortestCommonSupersequenceLength (line 8) | final class ShortestCommonSupersequenceLength { method ShortestCommonSupersequenceLength (line 9) | private ShortestCommonSupersequenceLength() { method shortestSuperSequence (line 21) | static int shortestSuperSequence(String x, String y) { method lcs (line 44) | static int lcs(String x, String y, int m, int n) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/SmithWaterman.java class SmithWaterman (line 10) | public final class SmithWaterman { method SmithWaterman (line 12) | private SmithWaterman() { method align (line 26) | public static int align(String s1, String s2, int matchScore, int mism... FILE: src/main/java/com/thealgorithms/dynamicprogramming/SubsetCount.java class SubsetCount (line 9) | public final class SubsetCount { method SubsetCount (line 10) | private SubsetCount() { method getCount (line 21) | public static int getCount(int[] arr, int target) { method getCountSO (line 55) | public static int getCountSO(int[] arr, int target) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/SubsetSum.java class SubsetSum (line 3) | public final class SubsetSum { method SubsetSum (line 4) | private SubsetSum() { method subsetSum (line 15) | public static boolean subsetSum(int[] arr, int sum) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/SubsetSumSpaceOptimized.java class SubsetSumSpaceOptimized (line 11) | public final class SubsetSumSpaceOptimized { method SubsetSumSpaceOptimized (line 12) | private SubsetSumSpaceOptimized() { method isSubsetSum (line 23) | public static boolean isSubsetSum(int[] nums, int targetSum) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/SumOfSubset.java class SumOfSubset (line 12) | public final class SumOfSubset { method SumOfSubset (line 14) | private SumOfSubset() { method subsetSum (line 33) | public static boolean subsetSum(int[] arr, int num, int key) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/TreeMatching.java class TreeMatching (line 17) | public class TreeMatching { method TreeMatching (line 27) | public TreeMatching(UndirectedAdjacencyListGraph graph) { method getMaxMatching (line 40) | public int getMaxMatching(int root, int parent) { method maxMatching (line 55) | private void maxMatching(int node, int parent) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/Tribonacci.java class Tribonacci (line 7) | public final class Tribonacci { method Tribonacci (line 8) | private Tribonacci() { method compute (line 17) | public static int compute(int n) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/UniquePaths.java class UniquePaths (line 19) | public final class UniquePaths { method UniquePaths (line 21) | private UniquePaths() { method uniquePaths (line 33) | public static int uniquePaths(final int m, final int n) { method uniquePaths2 (line 56) | public static int uniquePaths2(final int m, final int n) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/UniqueSubsequencesCount.java class UniqueSubsequencesCount (line 17) | public final class UniqueSubsequencesCount { method UniqueSubsequencesCount (line 25) | private UniqueSubsequencesCount() { method countSubseq (line 39) | public static int countSubseq(String str) { method countSubsequences (line 62) | public static int countSubsequences(String st, int idx, int[] dp) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/WildcardMatching.java class WildcardMatching (line 16) | public final class WildcardMatching { method WildcardMatching (line 17) | private WildcardMatching() { method isMatch (line 20) | public static boolean isMatch(String text, String pattern) { FILE: src/main/java/com/thealgorithms/dynamicprogramming/WineProblem.java class WineProblem (line 26) | public final class WineProblem { method WineProblem (line 27) | private WineProblem() { method wpRecursion (line 38) | public static int wpRecursion(int[] arr, int si, int ei) { method wptd (line 60) | public static int wptd(int[] arr, int si, int ei, int[][] strg) { method wpbu (line 86) | public static int wpbu(int[] arr) { FILE: src/main/java/com/thealgorithms/geometry/BentleyOttmann.java class BentleyOttmann (line 27) | public final class BentleyOttmann { method BentleyOttmann (line 29) | private BentleyOttmann() { class Segment (line 38) | public static class Segment { method Segment (line 43) | Segment(Point2D.Double p1, Point2D.Double p2) { method getY (line 54) | double getY(double x) { method leftPoint (line 63) | Point2D.Double leftPoint() { method rightPoint (line 67) | Point2D.Double rightPoint() { method toString (line 71) | @Override type EventType (line 80) | private enum EventType { START, END, INTERSECTION } class Event (line 85) | private static class Event implements Comparable { method Event (line 90) | Event(Point2D.Double point, EventType type) { method addSegment (line 96) | void addSegment(Segment s) { method compareTo (line 100) | @Override method equals (line 114) | @Override method hashCode (line 122) | @Override class StatusComparator (line 132) | private static final class StatusComparator implements Comparator findIntersections(List segm... method getOrCreateEvent (line 203) | private static Event getOrCreateEvent(Map event... method handleEvent (line 216) | private static void handleEvent(Event event, TreeSet status, ... method getNeighbor (line 288) | private static Segment getNeighbor(NavigableSet status, Set segments, SortedSet segments, SortedSet findLine(int x0, int y0, int x1, int y1) { FILE: src/main/java/com/thealgorithms/geometry/ConvexHull.java class ConvexHull (line 24) | public final class ConvexHull { method ConvexHull (line 25) | private ConvexHull() { method checkPointOrientation (line 28) | private static boolean checkPointOrientation(Point i, Point j, Point k) { method convexHullBruteForce (line 39) | public static List convexHullBruteForce(List points) { method convexHullRecursive (line 71) | public static List convexHullRecursive(List points) { method constructHull (line 105) | private static void constructHull(Collection points, Point left... method sortCounterClockwise (line 137) | private static List sortCounterClockwise(List hullPoints) { method distanceSquared (line 202) | private static long distanceSquared(Point p1, Point p2) { FILE: src/main/java/com/thealgorithms/geometry/DDALine.java class DDALine (line 17) | public final class DDALine { method DDALine (line 19) | private DDALine() { method findLine (line 32) | public static List findLine(int x0, int y0, int x1, int y1) { FILE: src/main/java/com/thealgorithms/geometry/GrahamScan.java class GrahamScan (line 18) | public class GrahamScan { method GrahamScan (line 22) | public GrahamScan(Point[] points) { method hull (line 65) | public Iterable hull() { FILE: src/main/java/com/thealgorithms/geometry/Haversine.java class Haversine (line 14) | public final class Haversine { method Haversine (line 22) | private Haversine() { method haversine (line 35) | public static double haversine(double lat1, double lon1, double lat2, ... FILE: src/main/java/com/thealgorithms/geometry/MidpointCircle.java class MidpointCircle (line 12) | public final class MidpointCircle { method MidpointCircle (line 14) | private MidpointCircle() { method generateCirclePoints (line 26) | public static List generateCirclePoints(int centerX, int center... method addSymmetricPoints (line 74) | private static void addSymmetricPoints(Collection points, int c... FILE: src/main/java/com/thealgorithms/geometry/MidpointEllipse.java class MidpointEllipse (line 12) | public final class MidpointEllipse { method MidpointEllipse (line 14) | private MidpointEllipse() { method drawEllipse (line 27) | public static List drawEllipse(int centerX, int centerY, int a,... method computeEllipsePoints (line 67) | private static void computeEllipsePoints(Collection points, int... method addEllipsePoints (line 125) | private static void addEllipsePoints(Collection points, int cen... FILE: src/main/java/com/thealgorithms/geometry/Point.java method compareTo (line 7) | @Override method toString (line 13) | @Override method polarOrder (line 18) | public Comparator polarOrder() { method orientation (line 22) | public static int orientation(Point a, Point b, Point c) { class PolarOrder (line 26) | private final class PolarOrder implements Comparator { method compare (line 27) | @Override FILE: src/main/java/com/thealgorithms/geometry/WusLine.java class WusLine (line 25) | public final class WusLine { method WusLine (line 27) | private WusLine() { class Pixel (line 37) | public static class Pixel { method Pixel (line 51) | public Pixel(int x, int y, double intensity) { class EndpointData (line 60) | private static class EndpointData { method EndpointData (line 66) | EndpointData(int xPixel, int yPixel, double yEnd, double xGap) { method drawLine (line 88) | public static List drawLine(int x0, int y0, int x1, int y1) { method processEndpoint (line 144) | private static EndpointData processEndpoint(double x, double y, double... method addEndpointPixels (line 162) | private static void addEndpointPixels(List pixels, EndpointData... method drawMainLine (line 184) | private static void drawMainLine(List pixels, EndpointData firs... method fpart (line 212) | private static double fpart(double x) { method rfpart (line 222) | private static double rfpart(double x) { method round (line 232) | private static double round(double x) { FILE: src/main/java/com/thealgorithms/graph/BronKerbosch.java class BronKerbosch (line 18) | public final class BronKerbosch { method BronKerbosch (line 20) | private BronKerbosch() { method findMaximalCliques (line 31) | public static List> findMaximalCliques(List>... method bronKerboschPivot (line 67) | private static void bronKerboschPivot(Set r, Set p, ... method choosePivot (line 90) | private static int choosePivot(Set p, Set x, List intersection(Set base, Set getEdges(int node) { method getNumNodes (line 56) | public int getNumNodes() { method ConstrainedShortestPath (line 73) | public ConstrainedShortestPath(Graph graph, int maxResource) { method solve (line 87) | public int solve(int start, int target) { FILE: src/main/java/com/thealgorithms/graph/Dinic.java class Dinic (line 23) | public final class Dinic { method Dinic (line 24) | private Dinic() { method maxFlow (line 37) | public static int maxFlow(int[][] capacity, int source, int sink) { method bfsBuildLevelGraph (line 78) | private static boolean bfsBuildLevelGraph(int[][] residual, int source... method dfsBlocking (line 98) | private static int dfsBlocking(int[][] residual, int[] level, int[] ne... FILE: src/main/java/com/thealgorithms/graph/Edmonds.java class Edmonds (line 32) | public final class Edmonds { method Edmonds (line 34) | private Edmonds() { class Edge (line 40) | public static class Edge { method Edge (line 52) | public Edge(int from, int to, long weight) { method findMinimumSpanningArborescence (line 70) | public static long findMinimumSpanningArborescence(int numVertices, Li... method findMSARecursive (line 84) | private static long findMSARecursive(int n, List edges, int root) { FILE: src/main/java/com/thealgorithms/graph/EdmondsKarp.java class EdmondsKarp (line 20) | public final class EdmondsKarp { method EdmondsKarp (line 22) | private EdmondsKarp() { method maxFlow (line 35) | public static int maxFlow(int[][] capacity, int source, int sink) { method bfs (line 86) | private static boolean bfs(int[][] residual, int source, int sink, int... FILE: src/main/java/com/thealgorithms/graph/GomoryHuTree.java class GomoryHuTree (line 15) | public final class GomoryHuTree { method GomoryHuTree (line 16) | private GomoryHuTree() { method buildTree (line 19) | public static int[][] buildTree(int[][] cap) { method validateCapacityMatrix (line 54) | private static void validateCapacityMatrix(int[][] cap) { class MaxFlowResult (line 71) | private static final class MaxFlowResult { method MaxFlowResult (line 74) | MaxFlowResult(int flow, boolean[] reachable) { method edmondsKarpWithMinCut (line 80) | private static MaxFlowResult edmondsKarpWithMinCut(int[][] capacity, i... method bfs (line 109) | private static boolean bfs(int[][] residual, int source, int sink, int... method markReachable (line 129) | private static void markReachable(int[][] residual, int source, boolea... FILE: src/main/java/com/thealgorithms/graph/HierholzerAlgorithm.java class HierholzerAlgorithm (line 33) | public final class HierholzerAlgorithm { method HierholzerAlgorithm (line 37) | public HierholzerAlgorithm(Map> graph) { method hasEulerianCircuit (line 41) | public boolean hasEulerianCircuit() { method findEulerianCircuit (line 55) | public List findEulerianCircuit() { method isCoherentlyConnected (line 101) | private boolean isCoherentlyConnected() { method dfs (line 130) | private void dfs(int u, Set visited) { FILE: src/main/java/com/thealgorithms/graph/HierholzerEulerianPath.java class HierholzerEulerianPath (line 38) | public class HierholzerEulerianPath { class Graph (line 43) | public static class Graph { method Graph (line 51) | public Graph(int numNodes) { method addEdge (line 64) | public void addEdge(int from, int to) { method getEdges (line 74) | public List getEdges(int node) { method getNumNodes (line 83) | public int getNumNodes() { method HierholzerEulerianPath (line 95) | public HierholzerEulerianPath(Graph graph) { method findEulerianPath (line 105) | public List findEulerianPath() { method computeDegrees (line 139) | private int computeDegrees(int[] inDegree, int[] outDegree) { method determineStartNode (line 151) | private int determineStartNode(int[] inDegree, int[] outDegree) { method buildHierholzerPath (line 184) | private List buildHierholzerPath(int startNode, int n) { method rotateEulerianCircuitIfNeeded (line 207) | private List rotateEulerianCircuitIfNeeded(List path... method allNonZeroDegreeVerticesWeaklyConnected (line 269) | private boolean allNonZeroDegreeVerticesWeaklyConnected(int startNode,... FILE: src/main/java/com/thealgorithms/graph/HopcroftKarp.java class HopcroftKarp (line 20) | public class HopcroftKarp { method HopcroftKarp (line 29) | public HopcroftKarp(int nLeft, int nRight, List> adj) { method maxMatching (line 42) | public int maxMatching() { method bfs (line 55) | private boolean bfs() { method dfs (line 83) | private boolean dfs(int u) { method getLeftMatches (line 96) | public int[] getLeftMatches() { method getRightMatches (line 100) | public int[] getRightMatches() { FILE: src/main/java/com/thealgorithms/graph/HungarianAlgorithm.java class HungarianAlgorithm (line 20) | public final class HungarianAlgorithm { method HungarianAlgorithm (line 22) | private HungarianAlgorithm() { class Result (line 26) | public static final class Result { method Result (line 30) | public Result(int[] assignment, int minCost) { method solve (line 43) | public static Result solve(int[][] cost) { method validate (line 131) | private static void validate(int[][] cost) { FILE: src/main/java/com/thealgorithms/graph/PredecessorConstrainedDfs.java class PredecessorConstrainedDfs (line 27) | public final class PredecessorConstrainedDfs { method PredecessorConstrainedDfs (line 29) | private PredecessorConstrainedDfs() { method visit (line 44) | public static TraversalEvent visit(T node, int order) { method skip (line 49) | public static TraversalEvent skip(T node, String note) { method isVisit (line 53) | public boolean isVisit() { method isSkip (line 57) | public boolean isSkip() { method toString (line 61) | @Override method dfsRecursiveOrder (line 80) | public static List> dfsRecursiveOrder(Map List> dfsRecursiveOrder(Map void dfs(T currentNode, Map> successors,... method allParentsVisited (line 131) | private static boolean allParentsVisited(T node, Set visited, M... method appearsAnywhere (line 140) | private static boolean appearsAnywhere(Map> successors,... method derivePredecessors (line 152) | private static Map> derivePredecessors(Map> ... FILE: src/main/java/com/thealgorithms/graph/PushRelabel.java class PushRelabel (line 20) | public final class PushRelabel { method PushRelabel (line 22) | private PushRelabel() { method maxFlow (line 34) | public static int maxFlow(int[][] capacity, int source, int sink) { method discharge (line 85) | private static void discharge(int u, State s) { class State (line 110) | private static final class State { method State (line 119) | State(int[][] residual, int[] height, int[] excess, int[] nextNeighb... method relabel (line 130) | private static void relabel(int u, int[][] residual, int[] height) { method validate (line 143) | private static void validate(int[][] capacity, int source, int sink) { FILE: src/main/java/com/thealgorithms/graph/StoerWagner.java class StoerWagner (line 11) | public class StoerWagner { method findMinCut (line 19) | public int findMinCut(int[][] graph) { FILE: src/main/java/com/thealgorithms/graph/StronglyConnectedComponentOptimized.java class StronglyConnectedComponentOptimized (line 16) | public class StronglyConnectedComponentOptimized { method btrack (line 18) | public void btrack(HashMap> adjList, int[] visi... method btrack2 (line 32) | public void btrack2(HashMap> adjRevList, int[] ... method getOutput (line 46) | public int getOutput(HashMap> adjList, int n) { FILE: src/main/java/com/thealgorithms/graph/TravelingSalesman.java class TravelingSalesman (line 14) | public final class TravelingSalesman { method TravelingSalesman (line 17) | private TravelingSalesman() { method bruteForce (line 27) | public static int bruteForce(int[][] distanceMatrix) { method calculateDistance (line 61) | public static int calculateDistance(int[][] distanceMatrix, List> generatePermutations(List ... method permute (line 93) | private static void permute(List arr, int k, List> kShortestPaths(int[][] weights, int ... method validate (line 112) | private static void validate(int[][] weights, int src, int dst, int k) { method startsWith (line 136) | private static boolean startsWith(List list, List pr... method cloneMatrix (line 148) | private static int[][] cloneMatrix(int[][] a) { method pathCost (line 157) | private static long pathCost(int[][] weights, List nodes) { method dijkstra (line 171) | private static Path dijkstra(int[][] weights, int src, int dst, boolea... class Node (line 223) | private static final class Node implements Comparable { method Node (line 226) | Node(int u, long dist) { method compareTo (line 230) | public int compareTo(Node o) { class Path (line 235) | private static final class Path implements Comparable { method Path (line 238) | Path(List nodes, long cost) { method key (line 242) | String key() { method compareTo (line 245) | @Override FILE: src/main/java/com/thealgorithms/graph/ZeroOneBfs.java class ZeroOneBfs (line 18) | public final class ZeroOneBfs { method ZeroOneBfs (line 20) | private ZeroOneBfs() { method shortestPaths (line 35) | public static int[] shortestPaths(int n, List> adj, int sr... FILE: src/main/java/com/thealgorithms/greedyalgorithms/ActivitySelection.java class ActivitySelection (line 9) | public final class ActivitySelection { method ActivitySelection (line 12) | private ActivitySelection() { method activitySelection (line 27) | public static ArrayList activitySelection(int[] startTimes, i... FILE: src/main/java/com/thealgorithms/greedyalgorithms/BandwidthAllocation.java class BandwidthAllocation (line 16) | public final class BandwidthAllocation { method BandwidthAllocation (line 17) | private BandwidthAllocation() { method maxValue (line 34) | public static int maxValue(int bandwidth, int[] users, int[] values) { FILE: src/main/java/com/thealgorithms/greedyalgorithms/BinaryAddition.java class BinaryAddition (line 8) | public class BinaryAddition { method sum (line 16) | public char sum(char a, char b, char carry) { method carry (line 36) | public char carry(char a, char b, char carry) { method addBinary (line 55) | public String addBinary(String a, String b) { FILE: src/main/java/com/thealgorithms/greedyalgorithms/CoinChange.java class CoinChange (line 9) | public final class CoinChange { method CoinChange (line 10) | private CoinChange() { method coinChangeProblem (line 13) | public static ArrayList coinChangeProblem(int amount) { FILE: src/main/java/com/thealgorithms/greedyalgorithms/DigitSeparation.java class DigitSeparation (line 10) | public class DigitSeparation { method DigitSeparation (line 11) | public DigitSeparation() { method digitSeparationReverseOrder (line 18) | public List digitSeparationReverseOrder(long largeNumber) { method digitSeparationForwardOrder (line 35) | public List digitSeparationForwardOrder(long largeNumber) { FILE: src/main/java/com/thealgorithms/greedyalgorithms/EgyptianFraction.java class EgyptianFraction (line 14) | public final class EgyptianFraction { method EgyptianFraction (line 15) | private EgyptianFraction() { method getEgyptianFraction (line 25) | public static List getEgyptianFraction(int numerator, int deno... FILE: src/main/java/com/thealgorithms/greedyalgorithms/FractionalKnapsack.java class FractionalKnapsack (line 17) | public final class FractionalKnapsack { method FractionalKnapsack (line 18) | private FractionalKnapsack() { method fractionalKnapsack (line 29) | public static int fractionalKnapsack(int[] weight, int[] value, int ca... FILE: src/main/java/com/thealgorithms/greedyalgorithms/GaleShapley.java class GaleShapley (line 11) | public final class GaleShapley { method GaleShapley (line 13) | private GaleShapley() { method stableMatch (line 23) | public static Map stableMatch(Map { method compareTo (line 19) | @Override method Job (line 24) | Job(char id, int deadline, int profit) { method findJobSequence (line 32) | public static String findJobSequence(ArrayList jobs, int size) { FILE: src/main/java/com/thealgorithms/greedyalgorithms/KCenters.java class KCenters (line 14) | public final class KCenters { method KCenters (line 15) | private KCenters() { method findKCenters (line 31) | public static int findKCenters(int[][] distances, int k) { FILE: src/main/java/com/thealgorithms/greedyalgorithms/MergeIntervals.java class MergeIntervals (line 15) | public final class MergeIntervals { method MergeIntervals (line 20) | private MergeIntervals() { method merge (line 41) | public static int[][] merge(int[][] intervals) { FILE: src/main/java/com/thealgorithms/greedyalgorithms/MinimizingLateness.java class MinimizingLateness (line 5) | public final class MinimizingLateness { method MinimizingLateness (line 6) | private MinimizingLateness() { class Job (line 9) | public static class Job { method Job (line 16) | public Job(String jobName, int processingTime, int deadline) { method of (line 22) | public static Job of(String jobName, int processingTime, int deadlin... method toString (line 26) | @Override method calculateLateness (line 32) | static void calculateLateness(Job... jobs) { FILE: src/main/java/com/thealgorithms/greedyalgorithms/MinimumWaitingTime.java class MinimumWaitingTime (line 11) | public final class MinimumWaitingTime { method MinimumWaitingTime (line 12) | private MinimumWaitingTime() { method minimumWaitingTime (line 23) | public static int minimumWaitingTime(int[] queries) { FILE: src/main/java/com/thealgorithms/greedyalgorithms/OptimalFileMerging.java class OptimalFileMerging (line 20) | public final class OptimalFileMerging { method OptimalFileMerging (line 21) | private OptimalFileMerging() { method minMergeCost (line 35) | public static int minMergeCost(int[] files) { FILE: src/main/java/com/thealgorithms/greedyalgorithms/StockProfitCalculator.java class StockProfitCalculator (line 10) | public final class StockProfitCalculator { method StockProfitCalculator (line 11) | private StockProfitCalculator() { method maxProfit (line 21) | public static int maxProfit(int[] prices) { FILE: src/main/java/com/thealgorithms/io/BufferedReader.java class BufferedReader (line 14) | public class BufferedReader { method BufferedReader (line 37) | public BufferedReader(byte[] input) throws IOException { method BufferedReader (line 41) | public BufferedReader(InputStream input) throws IOException { method BufferedReader (line 45) | public BufferedReader(InputStream input, int bufferSize) throws IOExce... method read (line 58) | public int read() throws IOException { method available (line 74) | public int available() throws IOException { method peek (line 88) | public int peek() throws IOException { method peek (line 96) | public int peek(int n) throws IOException { method pushRefreshData (line 116) | private void pushRefreshData() throws IOException { method readBlock (line 136) | public byte[] readBlock() throws IOException { method needsRefill (line 153) | private boolean needsRefill() { method refill (line 157) | private void refill() throws IOException { method justRefill (line 163) | private void justRefill() throws IOException { method assertStreamOpen (line 182) | private void assertStreamOpen() { method close (line 188) | public void close() throws IOException { FILE: src/main/java/com/thealgorithms/lineclipping/CohenSutherland.java class CohenSutherland (line 23) | public class CohenSutherland { method CohenSutherland (line 38) | public CohenSutherland(double xMin, double yMin, double xMax, double y... method computeCode (line 46) | private int computeCode(double x, double y) { method cohenSutherlandClip (line 68) | public Line cohenSutherlandClip(Line line) { FILE: src/main/java/com/thealgorithms/lineclipping/LiangBarsky.java class LiangBarsky (line 23) | public class LiangBarsky { method LiangBarsky (line 31) | public LiangBarsky(double xMin, double yMin, double xMax, double yMax) { method liangBarskyClip (line 39) | public Line liangBarskyClip(Line line) { method clipLine (line 56) | private double[] clipLine(double[] p, double[] q) { method calculateClippedLine (line 85) | private Line calculateClippedLine(Line line, double t0, double t1, dou... FILE: src/main/java/com/thealgorithms/lineclipping/utils/Line.java class Line (line 9) | public class Line { method Line (line 14) | public Line() { method Line (line 17) | public Line(Point start, Point end) { method equals (line 22) | @Override method hashCode (line 34) | @Override method toString (line 39) | @Override FILE: src/main/java/com/thealgorithms/lineclipping/utils/Point.java class Point (line 9) | public class Point { method Point (line 14) | public Point() { method Point (line 17) | public Point(double x, double y) { method equals (line 22) | @Override method hashCode (line 34) | @Override method toString (line 39) | @Override FILE: src/main/java/com/thealgorithms/maths/ADTFraction.java method plus (line 23) | public ADTFraction plus(ADTFraction fraction) { method times (line 35) | public ADTFraction times(int number) { method times (line 45) | public ADTFraction times(ADTFraction fraction) { method reciprocal (line 56) | public ADTFraction reciprocal() { method value (line 66) | public float value() { method toString (line 76) | @Override FILE: src/main/java/com/thealgorithms/maths/AbsoluteMax.java class AbsoluteMax (line 3) | public final class AbsoluteMax { method AbsoluteMax (line 4) | private AbsoluteMax() { method getMaxValue (line 14) | public static int getMaxValue(int... numbers) { FILE: src/main/java/com/thealgorithms/maths/AbsoluteMin.java class AbsoluteMin (line 5) | public final class AbsoluteMin { method AbsoluteMin (line 6) | private AbsoluteMin() { method getMinValue (line 15) | public static int getMinValue(int... numbers) { FILE: src/main/java/com/thealgorithms/maths/AbsoluteValue.java class AbsoluteValue (line 3) | public final class AbsoluteValue { method AbsoluteValue (line 4) | private AbsoluteValue() { method getAbsValue (line 13) | public static int getAbsValue(int number) { FILE: src/main/java/com/thealgorithms/maths/AbundantNumber.java class AbundantNumber (line 12) | public final class AbundantNumber { method AbundantNumber (line 14) | private AbundantNumber() { method sumOfDivisors (line 18) | private static int sumOfDivisors(int n) { method validatePositiveNumber (line 29) | private static void validatePositiveNumber(int number) { method isAbundant (line 41) | public static boolean isAbundant(int number) { method isAbundantNumber (line 53) | public static boolean isAbundantNumber(int number) { FILE: src/main/java/com/thealgorithms/maths/AliquotSum.java class AliquotSum (line 12) | public final class AliquotSum { method AliquotSum (line 13) | private AliquotSum() { method getAliquotValue (line 22) | public static int getAliquotValue(int number) { method getAliquotSum (line 36) | public static int getAliquotSum(int n) { FILE: src/main/java/com/thealgorithms/maths/AmicableNumber.java class AmicableNumber (line 22) | public final class AmicableNumber { method AmicableNumber (line 23) | private AmicableNumber() { method findAllInRange (line 32) | public static Set> findAllInRange(int from, int... method isAmicableNumber (line 52) | public static boolean isAmicableNumber(int a, int b) { method sumOfDividers (line 62) | private static int sumOfDividers(int number, int divisor) { FILE: src/main/java/com/thealgorithms/maths/Area.java class Area (line 6) | public final class Area { method Area (line 7) | private Area() { method surfaceAreaCube (line 31) | public static double surfaceAreaCube(final double sideLength) { method surfaceAreaCuboid (line 46) | public static double surfaceAreaCuboid(final double length, double wid... method surfaceAreaSphere (line 65) | public static double surfaceAreaSphere(final double radius) { method surfaceAreaPyramid (line 79) | public static double surfaceAreaPyramid(final double sideLength, final... method surfaceAreaRectangle (line 98) | public static double surfaceAreaRectangle(final double length, final d... method surfaceAreaCylinder (line 115) | public static double surfaceAreaCylinder(final double radius, final do... method surfaceAreaSquare (line 131) | public static double surfaceAreaSquare(final double sideLength) { method surfaceAreaTriangle (line 145) | public static double surfaceAreaTriangle(final double baseLength, fina... method surfaceAreaParallelogram (line 162) | public static double surfaceAreaParallelogram(final double baseLength,... method surfaceAreaTrapezium (line 180) | public static double surfaceAreaTrapezium(final double baseLength1, fi... method surfaceAreaCircle (line 199) | public static double surfaceAreaCircle(final double radius) { method surfaceAreaHemisphere (line 212) | public static double surfaceAreaHemisphere(final double radius) { method surfaceAreaCone (line 226) | public static double surfaceAreaCone(final double radius, final double... FILE: src/main/java/com/thealgorithms/maths/Armstrong.java class Armstrong (line 15) | public class Armstrong { method isArmstrong (line 23) | public boolean isArmstrong(int number) { FILE: src/main/java/com/thealgorithms/maths/AutoCorrelation.java class AutoCorrelation (line 10) | public final class AutoCorrelation { method AutoCorrelation (line 11) | private AutoCorrelation() { method autoCorrelation (line 21) | public static double[] autoCorrelation(double[] x) { FILE: src/main/java/com/thealgorithms/maths/AutomorphicNumber.java class AutomorphicNumber (line 11) | public final class AutomorphicNumber { method AutomorphicNumber (line 12) | private AutomorphicNumber() { method isAutomorphic (line 22) | public static boolean isAutomorphic(long n) { method isAutomorphic2 (line 44) | public static boolean isAutomorphic2(long n) { method isAutomorphic3 (line 59) | public static boolean isAutomorphic3(String s) { FILE: src/main/java/com/thealgorithms/maths/Average.java class Average (line 8) | public final class Average { method Average (line 11) | private Average() { method average (line 22) | public static double average(double[] numbers) { method average (line 40) | public static long average(int[] numbers) { FILE: src/main/java/com/thealgorithms/maths/BellNumbers.java class BellNumbers (line 17) | public final class BellNumbers { method BellNumbers (line 19) | private BellNumbers() { method compute (line 29) | public static long compute(int n) { FILE: src/main/java/com/thealgorithms/maths/BinaryPow.java class BinaryPow (line 3) | public final class BinaryPow { method BinaryPow (line 4) | private BinaryPow() { method binPow (line 15) | public static int binPow(int a, int p) { FILE: src/main/java/com/thealgorithms/maths/BinomialCoefficient.java class BinomialCoefficient (line 13) | public final class BinomialCoefficient { method BinomialCoefficient (line 14) | private BinomialCoefficient() { method binomialCoefficient (line 26) | public static int binomialCoefficient(int totalObjects, int numberOfOb... FILE: src/main/java/com/thealgorithms/maths/CatalanNumbers.java class CatalanNumbers (line 6) | public final class CatalanNumbers { method CatalanNumbers (line 7) | private CatalanNumbers() { method catalan (line 16) | public static long catalan(final int n) { method factorial (line 29) | private static long factorial(final int n) { FILE: src/main/java/com/thealgorithms/maths/Ceil.java class Ceil (line 6) | public final class Ceil { method Ceil (line 8) | private Ceil() { method ceil (line 18) | public static double ceil(double number) { FILE: src/main/java/com/thealgorithms/maths/ChebyshevIteration.java class ChebyshevIteration (line 21) | public final class ChebyshevIteration { method ChebyshevIteration (line 23) | private ChebyshevIteration() { method solve (line 46) | public static double[] solve(double[][] a, double[] b, double[] x0, do... method validateInputs (line 90) | private static void validateInputs(double[][] a, double[] b, double[] ... method matrixVectorMultiply (line 122) | private static double[] matrixVectorMultiply(double[][] a, double[] v) { method vectorSubtract (line 138) | private static double[] vectorSubtract(double[] v1, double[] v2) { method vectorAdd (line 150) | private static double[] vectorAdd(double[] v1, double[] v2) { method scalarMultiply (line 162) | private static double[] scalarMultiply(double scalar, double[] v) { method vectorNorm (line 174) | private static double vectorNorm(double[] v) { FILE: src/main/java/com/thealgorithms/maths/ChineseRemainderTheorem.java class ChineseRemainderTheorem (line 13) | public final class ChineseRemainderTheorem { method ChineseRemainderTheorem (line 14) | private ChineseRemainderTheorem() { method solveCRT (line 23) | public static int solveCRT(List remainders, List mod... method modInverse (line 55) | private static int modInverse(int a, int m) { FILE: src/main/java/com/thealgorithms/maths/CircularConvolutionFFT.java class CircularConvolutionFFT (line 13) | public final class CircularConvolutionFFT { method CircularConvolutionFFT (line 14) | private CircularConvolutionFFT() { method padding (line 23) | private static void padding(Collection x, int newSize) { method fftCircularConvolution (line 44) | public static ArrayList fftCircularConvolution(ArrayList<... FILE: src/main/java/com/thealgorithms/maths/CollatzConjecture.java class CollatzConjecture (line 9) | public class CollatzConjecture { method nextNumber (line 17) | public int nextNumber(final int n) { method collatzConjecture (line 30) | public List collatzConjecture(int firstNumber) { FILE: src/main/java/com/thealgorithms/maths/Combinations.java class Combinations (line 6) | public final class Combinations { method Combinations (line 7) | private Combinations() { method factorial (line 16) | public static long factorial(int n) { method combinations (line 30) | public static long combinations(int n, int k) { method combinationsOptimized (line 47) | public static long combinationsOptimized(int n, int k) { FILE: src/main/java/com/thealgorithms/maths/ComplexNumberMultiply.java class ComplexNumberMultiply (line 7) | public final class ComplexNumberMultiply { method ComplexNumberMultiply (line 9) | private ComplexNumberMultiply() { method parse (line 12) | private static int[] parse(String num) { method multiply (line 23) | public static String multiply(String num1, String num2) { FILE: src/main/java/com/thealgorithms/maths/Convolution.java class Convolution (line 9) | public final class Convolution { method Convolution (line 10) | private Convolution() { method convolution (line 22) | public static double[] convolution(double[] a, double[] b) { FILE: src/main/java/com/thealgorithms/maths/ConvolutionFFT.java class ConvolutionFFT (line 13) | public final class ConvolutionFFT { method ConvolutionFFT (line 14) | private ConvolutionFFT() { method padding (line 23) | private static void padding(Collection x, int newSize) { method convolutionFFT (line 48) | public static ArrayList convolutionFFT(ArrayList eulerFull(double xStart, double xEnd... FILE: src/main/java/com/thealgorithms/maths/EulerPseudoprime.java class EulerPseudoprime (line 18) | public final class EulerPseudoprime { method EulerPseudoprime (line 20) | private EulerPseudoprime() { method isProbablePrime (line 34) | public static boolean isProbablePrime(BigInteger n, int trials) { method jacobiSymbol (line 67) | public static int jacobiSymbol(BigInteger a, BigInteger n) { method uniformRandom (line 101) | private static BigInteger uniformRandom(BigInteger min, BigInteger max) { FILE: src/main/java/com/thealgorithms/maths/EulersFunction.java class EulersFunction (line 7) | public final class EulersFunction { method EulersFunction (line 8) | private EulersFunction() { method checkInput (line 17) | private static void checkInput(int n) { method getEuler (line 31) | public static int getEuler(int n) { FILE: src/main/java/com/thealgorithms/maths/EvilNumber.java class EvilNumber (line 10) | public final class EvilNumber { method EvilNumber (line 12) | private EvilNumber() { method countOneBits (line 16) | private static int countOneBits(int number) { method isEvilNumber (line 31) | public static boolean isEvilNumber(int number) { FILE: src/main/java/com/thealgorithms/maths/ExtendedEuclideanAlgorithm.java class ExtendedEuclideanAlgorithm (line 13) | public final class ExtendedEuclideanAlgorithm { method ExtendedEuclideanAlgorithm (line 15) | private ExtendedEuclideanAlgorithm() { method extendedGCD (line 30) | public static long[] extendedGCD(long a, long b) { FILE: src/main/java/com/thealgorithms/maths/FFT.java class FFT (line 14) | public final class FFT { method FFT (line 15) | private FFT() { class Complex (line 26) | static class Complex { method Complex (line 34) | Complex() { method Complex (line 45) | Complex(double r, double i) { method getReal (line 55) | public double getReal() { method getImaginary (line 64) | public double getImaginary() { method add (line 74) | public Complex add(Complex z) { method subtract (line 87) | public Complex subtract(Complex z) { method multiply (line 100) | public Complex multiply(Complex z) { method multiply (line 113) | public Complex multiply(double n) { method conjugate (line 125) | public Complex conjugate() { method abs (line 137) | public double abs() { method divide (line 147) | public Complex divide(Complex z) { method divide (line 162) | public Complex divide(double n) { method real (line 169) | public double real() { method imaginary (line 173) | public double imaginary() { method fft (line 195) | public static ArrayList fft(ArrayList x, boolean inv... method findLog2 (line 223) | public static int findLog2(int n) { method fftBitReversal (line 232) | public static ArrayList fftBitReversal(int n, int log2n, Arra... method inverseFFT (line 244) | public static ArrayList inverseFFT(int n, boolean inverse, Ar... method reverseBits (line 270) | private static int reverseBits(int num, int log2n) { method paddingPowerOfTwo (line 286) | private static void paddingPowerOfTwo(Collection x) { FILE: src/main/java/com/thealgorithms/maths/FFTBluestein.java class FFTBluestein (line 13) | public final class FFTBluestein { method FFTBluestein (line 14) | private FFTBluestein() { method fftBluestein (line 29) | public static void fftBluestein(List x, boolean inverse) { FILE: src/main/java/com/thealgorithms/maths/Factorial.java class Factorial (line 3) | public final class Factorial { method Factorial (line 4) | private Factorial() { method factorial (line 13) | public static long factorial(int n) { FILE: src/main/java/com/thealgorithms/maths/FastExponentiation.java class FastExponentiation (line 20) | public final class FastExponentiation { method FastExponentiation (line 25) | private FastExponentiation() { method fastExponentiation (line 42) | public static long fastExponentiation(long base, long exp, long mod) { FILE: src/main/java/com/thealgorithms/maths/FastInverseSqrt.java class FastInverseSqrt (line 8) | public final class FastInverseSqrt { method FastInverseSqrt (line 9) | private FastInverseSqrt() { method inverseSqrt (line 24) | public static boolean inverseSqrt(float number) { method inverseSqrt (line 39) | public static boolean inverseSqrt(double number) { FILE: src/main/java/com/thealgorithms/maths/FibonacciJavaStreams.java class FibonacciJavaStreams (line 12) | public final class FibonacciJavaStreams { method FibonacciJavaStreams (line 13) | private FibonacciJavaStreams() { method calculate (line 16) | public static Optional calculate(final BigDecimal index) { FILE: src/main/java/com/thealgorithms/maths/FibonacciLoop.java class FibonacciLoop (line 8) | public final class FibonacciLoop { method FibonacciLoop (line 10) | private FibonacciLoop() { method compute (line 21) | public static BigInteger compute(final int n) { FILE: src/main/java/com/thealgorithms/maths/FibonacciNumberCheck.java class FibonacciNumberCheck (line 8) | public final class FibonacciNumberCheck { method FibonacciNumberCheck (line 9) | private FibonacciNumberCheck() { method isPerfectSquare (line 18) | public static boolean isPerfectSquare(long number) { method isFibonacciNumber (line 32) | public static boolean isFibonacciNumber(long number) { FILE: src/main/java/com/thealgorithms/maths/FibonacciNumberGoldenRation.java class FibonacciNumberGoldenRation (line 9) | public final class FibonacciNumberGoldenRation { method FibonacciNumberGoldenRation (line 10) | private FibonacciNumberGoldenRation() { method compute (line 28) | public static long compute(int n) { FILE: src/main/java/com/thealgorithms/maths/FindKthNumber.java class FindKthNumber (line 10) | public final class FindKthNumber { method FindKthNumber (line 11) | private FindKthNumber() { method findKthMax (line 16) | public static int findKthMax(int[] array, int k) { method quickSelect (line 25) | private static int quickSelect(int[] array, int left, int right, int k... method partition (line 43) | private static int partition(int[] array, int left, int right, int piv... method swap (line 62) | private static void swap(int[] array, int i, int j) { method findKthMaxUsingHeap (line 68) | public static int findKthMaxUsingHeap(int[] array, int k) { FILE: src/main/java/com/thealgorithms/maths/FindMax.java class FindMax (line 3) | public final class FindMax { method FindMax (line 4) | private FindMax() { method findMax (line 14) | public static int findMax(final int[] array) { FILE: src/main/java/com/thealgorithms/maths/FindMaxRecursion.java class FindMaxRecursion (line 3) | public final class FindMaxRecursion { method FindMaxRecursion (line 5) | private FindMaxRecursion() { method max (line 15) | public static int max(final int[] array, final int low, final int high) { method max (line 37) | public static int max(final int[] array) { FILE: src/main/java/com/thealgorithms/maths/FindMin.java class FindMin (line 3) | public final class FindMin { method FindMin (line 4) | private FindMin() { method findMin (line 14) | public static int findMin(final int[] array) { FILE: src/main/java/com/thealgorithms/maths/FindMinRecursion.java class FindMinRecursion (line 3) | public final class FindMinRecursion { method FindMinRecursion (line 5) | private FindMinRecursion() { method min (line 17) | public static int min(final int[] array, final int low, final int high) { method min (line 39) | public static int min(final int[] array) { FILE: src/main/java/com/thealgorithms/maths/Floor.java class Floor (line 3) | public final class Floor { method Floor (line 5) | private Floor() { method floor (line 15) | public static double floor(double number) { FILE: src/main/java/com/thealgorithms/maths/FrizzyNumber.java class FrizzyNumber (line 7) | public final class FrizzyNumber { method FrizzyNumber (line 8) | private FrizzyNumber() { method getNthFrizzy (line 23) | public static double getNthFrizzy(int base, int n) { FILE: src/main/java/com/thealgorithms/maths/GCD.java class GCD (line 23) | public final class GCD { method GCD (line 24) | private GCD() { method gcd (line 34) | public static int gcd(int num1, int num2) { method gcd (line 57) | public static int gcd(int... numbers) { FILE: src/main/java/com/thealgorithms/maths/GCDRecursion.java class GCDRecursion (line 6) | public final class GCDRecursion { method GCDRecursion (line 7) | private GCDRecursion() { method main (line 10) | public static void main(String[] args) { method gcd (line 26) | public static int gcd(int a, int b) { FILE: src/main/java/com/thealgorithms/maths/Gaussian.java class Gaussian (line 6) | public final class Gaussian { method Gaussian (line 7) | private Gaussian() { method gaussian (line 10) | public static ArrayList gaussian(int matSize, List mat... method gaussianElimination (line 29) | public static double[][] gaussianElimination(int matSize, int i, doubl... method valueOfGaussian (line 44) | public static ArrayList valueOfGaussian(int matSize, double[][... FILE: src/main/java/com/thealgorithms/maths/GenericRoot.java class GenericRoot (line 13) | public final class GenericRoot { method GenericRoot (line 17) | private GenericRoot() { method sumOfDigits (line 26) | private static int sumOfDigits(final int n) { method genericRoot (line 41) | public static int genericRoot(final int n) { FILE: src/main/java/com/thealgorithms/maths/GermainPrimeAndSafePrime.java class GermainPrimeAndSafePrime (line 24) | public final class GermainPrimeAndSafePrime { method GermainPrimeAndSafePrime (line 27) | private GermainPrimeAndSafePrime() { method isGermainPrime (line 39) | public static boolean isGermainPrime(int number) { method isSafePrime (line 56) | public static boolean isSafePrime(int number) { FILE: src/main/java/com/thealgorithms/maths/GoldbachConjecture.java class GoldbachConjecture (line 12) | public final class GoldbachConjecture { method GoldbachConjecture (line 13) | private GoldbachConjecture() { method getPrimeSum (line 18) | public static Result getPrimeSum(int number) { FILE: src/main/java/com/thealgorithms/maths/HappyNumber.java class HappyNumber (line 14) | public final class HappyNumber { method HappyNumber (line 16) | private HappyNumber() { method isHappy (line 27) | public static boolean isHappy(int n) { method sumOfSquares (line 48) | private static int sumOfSquares(int num) { FILE: src/main/java/com/thealgorithms/maths/HarshadNumber.java class HarshadNumber (line 14) | public final class HarshadNumber { method HarshadNumber (line 15) | private HarshadNumber() { method isHarshad (line 28) | public static boolean isHarshad(long n) { method isHarshad (line 55) | public static boolean isHarshad(String s) { FILE: src/main/java/com/thealgorithms/maths/HeronsFormula.java class HeronsFormula (line 17) | public final class HeronsFormula { method HeronsFormula (line 22) | private HeronsFormula() { method areAllSidesPositive (line 33) | private static boolean areAllSidesPositive(final double a, final doubl... method canFormTriangle (line 49) | private static boolean canFormTriangle(final double a, final double b,... method herons (line 68) | public static double herons(final double a, final double b, final doub... FILE: src/main/java/com/thealgorithms/maths/JosephusProblem.java class JosephusProblem (line 20) | public final class JosephusProblem { method JosephusProblem (line 21) | private JosephusProblem() { method findTheWinner (line 31) | public static int findTheWinner(int n, int k) { method winner (line 35) | public static int winner(int n, int k) { FILE: src/main/java/com/thealgorithms/maths/JugglerSequence.java class JugglerSequence (line 14) | public final class JugglerSequence { method JugglerSequence (line 15) | private JugglerSequence() { method jugglerSequence (line 23) | public static void jugglerSequence(int inputNumber) { method main (line 50) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/maths/KaprekarNumbers.java class KaprekarNumbers (line 30) | public final class KaprekarNumbers { method KaprekarNumbers (line 31) | private KaprekarNumbers() { method kaprekarNumberInRange (line 43) | public static List kaprekarNumberInRange(long start, long end) { method isKaprekarNumber (line 79) | public static boolean isKaprekarNumber(long num) { FILE: src/main/java/com/thealgorithms/maths/KaratsubaMultiplication.java class KaratsubaMultiplication (line 40) | public final class KaratsubaMultiplication { method KaratsubaMultiplication (line 45) | private KaratsubaMultiplication() { method karatsuba (line 60) | public static BigInteger karatsuba(BigInteger x, BigInteger y) { FILE: src/main/java/com/thealgorithms/maths/KeithNumber.java class KeithNumber (line 26) | public final class KeithNumber { method KeithNumber (line 27) | private KeithNumber() { method isKeith (line 46) | public static boolean isKeith(int number) { method main (line 89) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/maths/KrishnamurthyNumber.java class KrishnamurthyNumber (line 36) | public final class KrishnamurthyNumber { method KrishnamurthyNumber (line 41) | private KrishnamurthyNumber() { method isKrishnamurthy (line 55) | public static boolean isKrishnamurthy(int n) { FILE: src/main/java/com/thealgorithms/maths/LeastCommonMultiple.java class LeastCommonMultiple (line 9) | public final class LeastCommonMultiple { method LeastCommonMultiple (line 10) | private LeastCommonMultiple() { method lcm (line 20) | public static int lcm(int num1, int num2) { FILE: src/main/java/com/thealgorithms/maths/LeonardoNumber.java class LeonardoNumber (line 19) | public final class LeonardoNumber { method LeonardoNumber (line 20) | private LeonardoNumber() { method leonardoNumber (line 37) | public static int leonardoNumber(int n) { method leonardoNumberIterative (line 60) | public static int leonardoNumberIterative(int n) { FILE: src/main/java/com/thealgorithms/maths/LinearDiophantineEquationsSolver.java class LinearDiophantineEquationsSolver (line 25) | public final class LinearDiophantineEquationsSolver { method LinearDiophantineEquationsSolver (line 26) | private LinearDiophantineEquationsSolver() { method main (line 34) | public static void main(String[] args) { method findAnySolution (line 55) | public static Solution findAnySolution(final Equation equation) { method gcd (line 101) | private static GcdSolutionWrapper gcd(final int a, final int b, final ... class Solution (line 125) | public static final class Solution { method Solution (line 146) | public Solution(int x, int y) { method getX (line 156) | public int getX() { method getY (line 165) | public int getY() { method setX (line 174) | public void setX(int x) { method setY (line 183) | public void setY(int y) { method equals (line 187) | @Override method hashCode (line 199) | @Override method toString (line 204) | @Override class GcdSolutionWrapper (line 230) | public static final class GcdSolutionWrapper { method GcdSolutionWrapper (line 241) | public GcdSolutionWrapper(int gcd, Solution solution) { method equals (line 246) | @Override method getGcd (line 263) | public int getGcd() { method setGcd (line 272) | public void setGcd(int gcd) { method getSolution (line 281) | public Solution getSolution() { method setSolution (line 290) | public void setSolution(Solution solution) { method hashCode (line 294) | @Override method toString (line 299) | @Override FILE: src/main/java/com/thealgorithms/maths/LongDivision.java class LongDivision (line 11) | public final class LongDivision { method LongDivision (line 12) | private LongDivision() { method divide (line 14) | public static int divide(int dividend, int divisor) { FILE: src/main/java/com/thealgorithms/maths/LucasSeries.java class LucasSeries (line 14) | public final class LucasSeries { method LucasSeries (line 15) | private LucasSeries() { method lucasSeries (line 27) | public static int lucasSeries(int n) { method lucasSeriesIteration (line 49) | public static int lucasSeriesIteration(int n) { FILE: src/main/java/com/thealgorithms/maths/LuckyNumber.java class LuckyNumber (line 11) | public final class LuckyNumber { method LuckyNumber (line 13) | private LuckyNumber() { method validatePositiveNumber (line 17) | private static void validatePositiveNumber(int number) { method isLuckyRecursiveApproach (line 24) | private static boolean isLuckyRecursiveApproach(int n, int counter) { method isLuckyNumber (line 48) | public static boolean isLuckyNumber(int number) { method isLucky (line 60) | public static boolean isLucky(int number) { FILE: src/main/java/com/thealgorithms/maths/MagicSquare.java class MagicSquare (line 8) | public final class MagicSquare { method MagicSquare (line 9) | private MagicSquare() { method main (line 12) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/maths/MathBuilder.java class MathBuilder (line 13) | public final class MathBuilder { method MathBuilder (line 16) | private MathBuilder(Builder builder) { method get (line 21) | public double get() { method toLong (line 26) | public long toLong() { class Builder (line 49) | public static class Builder { method Builder (line 55) | public Builder() { method Builder (line 59) | public Builder(double num) { method add (line 63) | public Builder add(double num) { method addIf (line 73) | public Builder addIf(double num, BiFunction... method minus (line 85) | public Builder minus(double num) { method minusIf (line 95) | public Builder minusIf(double num, BiFunction... method pow (line 243) | public Builder pow(double num) { method sqrt (line 252) | public Builder sqrt() { method round (line 261) | public Builder round() { method floor (line 270) | public Builder floor() { method ceil (line 279) | public Builder ceil() { method abs (line 288) | public Builder abs() { method cbrt (line 297) | public Builder cbrt() { method log (line 306) | public Builder log() { method log10 (line 315) | public Builder log10() { method sin (line 324) | public Builder sin() { method cos (line 333) | public Builder cos() { method tan (line 342) | public Builder tan() { method sinh (line 351) | public Builder sinh() { method cosh (line 360) | public Builder cosh() { method tanh (line 369) | public Builder tanh() { method exp (line 378) | public Builder exp() { method toRadians (line 387) | public Builder toRadians() { method remember (line 397) | public Builder remember() { method recall (line 403) | public Builder recall(boolean cleanMemory) { method recallIf (line 412) | public Builder recallIf(Function condition, boolean... method set (line 424) | public Builder set(double num) { method setIf (line 433) | public Builder setIf(double num, BiFunction... method print (line 444) | public Builder print() { method openParenthesis (line 449) | public Builder openParenthesis(double num) { method closeParenthesisAndPlus (line 455) | public Builder closeParenthesisAndPlus() { method closeParenthesisAndMinus (line 462) | public Builder closeParenthesisAndMinus() { method closeParenthesisAndMultiply (line 469) | public Builder closeParenthesisAndMultiply() { method closeParenthesisAndDivide (line 476) | public Builder closeParenthesisAndDivide() { method format (line 483) | public Builder format(String format) { method format (line 490) | public Builder format(int decimalPlace) { method build (line 499) | public MathBuilder build() { FILE: src/main/java/com/thealgorithms/maths/MaxValue.java class MaxValue (line 3) | public final class MaxValue { method MaxValue (line 4) | private MaxValue() { method max (line 15) | public static int max(int a, int b) { FILE: src/main/java/com/thealgorithms/maths/Means.java class Means (line 29) | public final class Means { method Means (line 31) | private Means() { method arithmetic (line 49) | public static Double arithmetic(final Iterable numbers) { method geometric (line 76) | public static Double geometric(final Iterable numbers) { method harmonic (line 103) | public static Double harmonic(final Iterable numbers) { method quadratic (line 125) | public static Double quadratic(final Iterable numbers) { method checkIfNotEmpty (line 138) | private static void checkIfNotEmpty(final Iterable numbers) { FILE: src/main/java/com/thealgorithms/maths/Median.java class Median (line 21) | public final class Median { method Median (line 22) | private Median() { method median (line 36) | public static double median(int[] values) { FILE: src/main/java/com/thealgorithms/maths/MinValue.java class MinValue (line 3) | public final class MinValue { method MinValue (line 4) | private MinValue() { method min (line 15) | public static int min(int a, int b) { FILE: src/main/java/com/thealgorithms/maths/Mode.java class Mode (line 16) | public final class Mode { method Mode (line 17) | private Mode() { method mode (line 30) | public static int[] mode(final int[] numbers) { FILE: src/main/java/com/thealgorithms/maths/Neville.java class Neville (line 17) | public final class Neville { method Neville (line 19) | private Neville() { method interpolate (line 33) | public static double interpolate(double[] x, double[] y, double target) { FILE: src/main/java/com/thealgorithms/maths/NonRepeatingElement.java class NonRepeatingElement (line 22) | public final class NonRepeatingElement { method NonRepeatingElement (line 23) | private NonRepeatingElement() { method findNonRepeatingElements (line 33) | public static int[] findNonRepeatingElements(int[] arr) { FILE: src/main/java/com/thealgorithms/maths/NthUglyNumber.java class NthUglyNumber (line 19) | public class NthUglyNumber { method NthUglyNumber (line 28) | NthUglyNumber(final int[] baseNumbers) { method get (line 43) | public Long get(final int n) { method addUglyNumber (line 55) | private void addUglyNumber() { method updatePositions (line 60) | private void updatePositions() { method computeCandidate (line 69) | private long computeCandidate(final Map.Entry entry) { method computeMinimalCandidate (line 73) | private long computeMinimalCandidate() { FILE: src/main/java/com/thealgorithms/maths/NumberOfDigits.java class NumberOfDigits (line 6) | public final class NumberOfDigits { method NumberOfDigits (line 7) | private NumberOfDigits() { method numberOfDigits (line 15) | public static int numberOfDigits(int number) { method numberOfDigitsFast (line 30) | public static int numberOfDigitsFast(int number) { method numberOfDigitsFaster (line 40) | public static int numberOfDigitsFaster(int number) { method numberOfDigitsRecursion (line 50) | public static int numberOfDigitsRecursion(int number) { FILE: src/main/java/com/thealgorithms/maths/NumberPersistence.java class NumberPersistence (line 16) | public final class NumberPersistence { method NumberPersistence (line 19) | private NumberPersistence() { method multiplicativePersistence (line 32) | public static int multiplicativePersistence(int num) { method additivePersistence (line 61) | public static int additivePersistence(int num) { FILE: src/main/java/com/thealgorithms/maths/PalindromeNumber.java class PalindromeNumber (line 3) | public final class PalindromeNumber { method PalindromeNumber (line 4) | private PalindromeNumber() { method isPalindrome (line 13) | public static boolean isPalindrome(int number) { FILE: src/main/java/com/thealgorithms/maths/ParseInteger.java class ParseInteger (line 3) | public final class ParseInteger { method ParseInteger (line 4) | private ParseInteger() { method checkInput (line 7) | private static void checkInput(final String s) { method checkDigitAt (line 16) | private static void checkDigitAt(final String s, final int pos) { method digitToInt (line 22) | private static int digitToInt(final char digit) { method parseInt (line 34) | public static int parseInt(final String s) { FILE: src/main/java/com/thealgorithms/maths/PascalTriangle.java class PascalTriangle (line 3) | public final class PascalTriangle { method PascalTriangle (line 4) | private PascalTriangle() { method pascal (line 39) | public static int[][] pascal(int n) { FILE: src/main/java/com/thealgorithms/maths/PerfectCube.java class PerfectCube (line 6) | public final class PerfectCube { method PerfectCube (line 7) | private PerfectCube() { method isPerfectCube (line 17) | public static boolean isPerfectCube(int number) { method isPerfectCubeMathCbrt (line 30) | public static boolean isPerfectCubeMathCbrt(int number) { FILE: src/main/java/com/thealgorithms/maths/PerfectNumber.java class PerfectNumber (line 11) | public final class PerfectNumber { method PerfectNumber (line 12) | private PerfectNumber() { method isPerfectNumber (line 21) | public static boolean isPerfectNumber(int number) { method isPerfectNumber2 (line 41) | public static boolean isPerfectNumber2(int n) { FILE: src/main/java/com/thealgorithms/maths/PerfectSquare.java class PerfectSquare (line 6) | public final class PerfectSquare { method PerfectSquare (line 7) | private PerfectSquare() { method isPerfectSquare (line 17) | public static boolean isPerfectSquare(final int number) { method isPerfectSquareUsingPow (line 32) | public static boolean isPerfectSquareUsingPow(long number) { FILE: src/main/java/com/thealgorithms/maths/Perimeter.java class Perimeter (line 4) | public final class Perimeter { method Perimeter (line 5) | private Perimeter() { method perimeterRegularPolygon (line 17) | public static float perimeterRegularPolygon(int n, float side) { method perimeterIrregularPolygon (line 32) | public static float perimeterIrregularPolygon(float side1, float side2... method perimeterRectangle (line 47) | public static float perimeterRectangle(float length, float breadth) { method perimeterCircle (line 57) | public static double perimeterCircle(float r) { FILE: src/main/java/com/thealgorithms/maths/PiApproximation.java class PiApproximation (line 17) | public final class PiApproximation { method PiApproximation (line 19) | private PiApproximation() { class Point (line 27) | static class Point { method Point (line 31) | Point(double x, double y) { method approximatePi (line 44) | public static double approximatePi(List pts) { method generateRandomPoints (line 62) | public static List generateRandomPoints(int numPoints) { FILE: src/main/java/com/thealgorithms/maths/PiNilakantha.java class PiNilakantha (line 3) | public final class PiNilakantha { method PiNilakantha (line 4) | private PiNilakantha() { method main (line 10) | public static void main(String[] args) { method calculatePi (line 25) | public static double calculatePi(int iterations) { FILE: src/main/java/com/thealgorithms/maths/PollardRho.java class PollardRho (line 38) | public final class PollardRho { method PollardRho (line 39) | private PollardRho() { method g (line 50) | static int g(int base, int modulus) { method pollardRho (line 61) | static int pollardRho(int number) { FILE: src/main/java/com/thealgorithms/maths/Pow.java class Pow (line 10) | public final class Pow { method Pow (line 11) | private Pow() { method pow (line 26) | public static long pow(int a, int b) { FILE: src/main/java/com/thealgorithms/maths/PowerOfFour.java class PowerOfFour (line 10) | public final class PowerOfFour { method PowerOfFour (line 11) | private PowerOfFour() { method isPowerOfFour (line 28) | public static boolean isPowerOfFour(int number) { FILE: src/main/java/com/thealgorithms/maths/PowerOfTwoOrNot.java class PowerOfTwoOrNot (line 7) | public final class PowerOfTwoOrNot { method PowerOfTwoOrNot (line 8) | private PowerOfTwoOrNot() { method checkIfPowerOfTwoOrNot (line 18) | public static boolean checkIfPowerOfTwoOrNot(final int number) { FILE: src/main/java/com/thealgorithms/maths/PowerUsingRecursion.java class PowerUsingRecursion (line 8) | public final class PowerUsingRecursion { method PowerUsingRecursion (line 9) | private PowerUsingRecursion() { method power (line 12) | public static double power(double base, int exponent) { FILE: src/main/java/com/thealgorithms/maths/Prime/LiouvilleLambdaFunction.java class LiouvilleLambdaFunction (line 15) | public final class LiouvilleLambdaFunction { method LiouvilleLambdaFunction (line 16) | private LiouvilleLambdaFunction() { method liouvilleLambda (line 27) | public static int liouvilleLambda(int number) { FILE: src/main/java/com/thealgorithms/maths/Prime/MillerRabinPrimalityCheck.java class MillerRabinPrimalityCheck (line 5) | public final class MillerRabinPrimalityCheck { method MillerRabinPrimalityCheck (line 6) | private MillerRabinPrimalityCheck() { method millerRabin (line 22) | public static boolean millerRabin(long n, int k) { // returns true if ... method deterministicMillerRabin (line 43) | public static boolean deterministicMillerRabin(long n) { // returns tr... method checkComposite (line 77) | private static boolean checkComposite(long n, long a, long d, int s) { method powerModP (line 91) | private static long powerModP(long x, long y, long p) { method multiplyModP (line 112) | private static long multiplyModP(long a, long b, long p) { FILE: src/main/java/com/thealgorithms/maths/Prime/MobiusFunction.java class MobiusFunction (line 15) | public final class MobiusFunction { method MobiusFunction (line 16) | private MobiusFunction() { method mobius (line 28) | public static int mobius(int number) { FILE: src/main/java/com/thealgorithms/maths/Prime/PrimeCheck.java class PrimeCheck (line 5) | public final class PrimeCheck { method PrimeCheck (line 6) | private PrimeCheck() { method main (line 9) | public static void main(String[] args) { method isPrime (line 35) | public static boolean isPrime(int n) { method fermatPrimeChecking (line 57) | public static boolean fermatPrimeChecking(int n, int iteration) { method modPow (line 77) | private static long modPow(long a, long b, long c) { FILE: src/main/java/com/thealgorithms/maths/Prime/PrimeFactorization.java class PrimeFactorization (line 12) | public final class PrimeFactorization { method PrimeFactorization (line 13) | private PrimeFactorization() { method pfactors (line 16) | public static List pfactors(int n) { FILE: src/main/java/com/thealgorithms/maths/Prime/SquareFreeInteger.java class SquareFreeInteger (line 17) | public final class SquareFreeInteger { method SquareFreeInteger (line 18) | private SquareFreeInteger() { method isSquareFreeInteger (line 28) | public static boolean isSquareFreeInteger(int number) { FILE: src/main/java/com/thealgorithms/maths/PronicNumber.java class PronicNumber (line 13) | public final class PronicNumber { method PronicNumber (line 14) | private PronicNumber() { method isPronic (line 23) | static boolean isPronic(int inputNumber) { method isPronicNumber (line 47) | public static boolean isPronicNumber(int number) { FILE: src/main/java/com/thealgorithms/maths/PythagoreanTriple.java class PythagoreanTriple (line 14) | public final class PythagoreanTriple { method PythagoreanTriple (line 16) | private PythagoreanTriple() { method isPythagTriple (line 28) | public static boolean isPythagTriple(int a, int b, int c) { FILE: src/main/java/com/thealgorithms/maths/QuadraticEquationSolver.java class ComplexNumber (line 6) | class ComplexNumber { method ComplexNumber (line 10) | ComplexNumber(double real, double imaginary) { method ComplexNumber (line 15) | ComplexNumber(double real) { class QuadraticEquationSolver (line 27) | public class QuadraticEquationSolver { method solveEquation (line 36) | public ComplexNumber[] solveEquation(double a, double b, double c) { FILE: src/main/java/com/thealgorithms/maths/ReverseNumber.java class ReverseNumber (line 6) | public final class ReverseNumber { method ReverseNumber (line 7) | private ReverseNumber() { method reverseNumber (line 16) | public static int reverseNumber(int number) { FILE: src/main/java/com/thealgorithms/maths/RomanNumeralUtil.java class RomanNumeralUtil (line 11) | public final class RomanNumeralUtil { method RomanNumeralUtil (line 12) | private RomanNumeralUtil() { method generate (line 66) | public static String generate(int number) { FILE: src/main/java/com/thealgorithms/maths/SecondMinMax.java class SecondMinMax (line 5) | public final class SecondMinMax { method SecondMinMax (line 14) | private SecondMinMax() { method secondBest (line 17) | private static int secondBest(final int[] arr, final int initialVal, f... method findSecondMin (line 41) | public static int findSecondMin(final int[] arr) { method findSecondMax (line 45) | public static int findSecondMax(final int[] arr) { method checkInput (line 49) | private static void checkInput(final int[] arr) { method checkOutput (line 55) | private static void checkOutput(final int secNum, final int initialVal) { FILE: src/main/java/com/thealgorithms/maths/SieveOfAtkin.java class SieveOfAtkin (line 14) | public final class SieveOfAtkin { method SieveOfAtkin (line 16) | private SieveOfAtkin() { method generatePrimes (line 27) | public static List generatePrimes(int limit) { method markQuadraticResidues (line 66) | private static void markQuadraticResidues(int limit, int sqrtLimit, bo... method applyQuadraticForm (line 84) | private static void applyQuadraticForm(int n, int limit, boolean[] sie... method applyQuadraticForm (line 99) | private static void applyQuadraticForm(int n, int limit, boolean[] sie... method applyQuadraticForm (line 116) | private static void applyQuadraticForm(int n, int limit, boolean[] sie... method eliminateMultiplesOfSquares (line 132) | private static void eliminateMultiplesOfSquares(int limit, int sqrtLim... FILE: src/main/java/com/thealgorithms/maths/SieveOfEratosthenes.java class SieveOfEratosthenes (line 24) | public final class SieveOfEratosthenes { method SieveOfEratosthenes (line 26) | private SieveOfEratosthenes() { method findPrimes (line 37) | public static List findPrimes(int n) { method countPrimes (line 79) | public static int countPrimes(int n) { FILE: src/main/java/com/thealgorithms/maths/SimpsonIntegration.java class SimpsonIntegration (line 5) | public class SimpsonIntegration { method main (line 18) | public static void main(String[] args) { method simpsonsMethod (line 48) | public double simpsonsMethod(int n, double h, double a) { method f (line 84) | public double f(double x) { FILE: src/main/java/com/thealgorithms/maths/SmithNumber.java class SmithNumber (line 14) | public final class SmithNumber { method SmithNumber (line 16) | private SmithNumber() { method primeFactorDigitSum (line 19) | private static int primeFactorDigitSum(int n) { method isSmithNumber (line 45) | public static boolean isSmithNumber(int number) { FILE: src/main/java/com/thealgorithms/maths/SolovayStrassenPrimalityTest.java class SolovayStrassenPrimalityTest (line 12) | final class SolovayStrassenPrimalityTest { method SolovayStrassenPrimalityTest (line 21) | private SolovayStrassenPrimalityTest(int seed) { method getSolovayStrassenPrimalityTest (line 31) | public static SolovayStrassenPrimalityTest getSolovayStrassenPrimality... method calculateModularExponentiation (line 43) | private static long calculateModularExponentiation(long base, long exp... method calculateJacobi (line 67) | public int calculateJacobi(long a, long num) { method solovayStrassen (line 108) | public boolean solovayStrassen(long num, int iterations) { FILE: src/main/java/com/thealgorithms/maths/SquareRootWithBabylonianMethod.java class SquareRootWithBabylonianMethod (line 3) | public final class SquareRootWithBabylonianMethod { method SquareRootWithBabylonianMethod (line 4) | private SquareRootWithBabylonianMethod() { method squareRoot (line 13) | public static float squareRoot(float num) { FILE: src/main/java/com/thealgorithms/maths/SquareRootWithNewtonRaphsonMethod.java class SquareRootWithNewtonRaphsonMethod (line 17) | public final class SquareRootWithNewtonRaphsonMethod { method SquareRootWithNewtonRaphsonMethod (line 18) | private SquareRootWithNewtonRaphsonMethod() { method squareRoot (line 21) | public static double squareRoot(int n) { FILE: src/main/java/com/thealgorithms/maths/StandardDeviation.java class StandardDeviation (line 3) | public final class StandardDeviation { method StandardDeviation (line 4) | private StandardDeviation() { method stdDev (line 7) | public static double stdDev(double[] data) { FILE: src/main/java/com/thealgorithms/maths/StandardScore.java class StandardScore (line 3) | public final class StandardScore { method StandardScore (line 4) | private StandardScore() { method zScore (line 7) | public static double zScore(double num, double mean, double stdDev) { FILE: src/main/java/com/thealgorithms/maths/StrobogrammaticNumber.java class StrobogrammaticNumber (line 12) | public class StrobogrammaticNumber { method isStrobogrammatic (line 18) | public boolean isStrobogrammatic(String number) { FILE: src/main/java/com/thealgorithms/maths/SumOfArithmeticSeries.java class SumOfArithmeticSeries (line 13) | public final class SumOfArithmeticSeries { method SumOfArithmeticSeries (line 14) | private SumOfArithmeticSeries() { method sumOfSeries (line 25) | public static double sumOfSeries(final double firstTerm, final double ... FILE: src/main/java/com/thealgorithms/maths/SumOfDigits.java class SumOfDigits (line 3) | public final class SumOfDigits { method SumOfDigits (line 4) | private SumOfDigits() { method sumOfDigits (line 13) | public static int sumOfDigits(int number) { method sumOfDigitsRecursion (line 30) | public static int sumOfDigitsRecursion(int number) { method sumOfDigitsFast (line 42) | public static int sumOfDigitsFast(final int number) { FILE: src/main/java/com/thealgorithms/maths/SumOfOddNumbers.java class SumOfOddNumbers (line 9) | public final class SumOfOddNumbers { method SumOfOddNumbers (line 10) | private SumOfOddNumbers() { method sumOfFirstNOddNumbers (line 19) | public static int sumOfFirstNOddNumbers(final int n) { FILE: src/main/java/com/thealgorithms/maths/SumOfSquares.java class SumOfSquares (line 10) | public final class SumOfSquares { method SumOfSquares (line 12) | private SumOfSquares() { method minSquares (line 22) | public static int minSquares(int n) { method isPerfectSquare (line 46) | private static boolean isPerfectSquare(int n) { FILE: src/main/java/com/thealgorithms/maths/SumWithoutArithmeticOperators.java class SumWithoutArithmeticOperators (line 3) | public class SumWithoutArithmeticOperators { method getSum (line 14) | public int getSum(int a, int b) { FILE: src/main/java/com/thealgorithms/maths/TrinomialTriangle.java class TrinomialTriangle (line 10) | public final class TrinomialTriangle { method TrinomialTriangle (line 11) | private TrinomialTriangle() { method trinomialValue (line 14) | public static int trinomialValue(int n, int k) { method printTrinomial (line 26) | public static void printTrinomial(int n) { method main (line 40) | public static void main(String[] argc) { FILE: src/main/java/com/thealgorithms/maths/TwinPrime.java class TwinPrime (line 14) | public final class TwinPrime { method TwinPrime (line 15) | private TwinPrime() { method getTwinPrime (line 24) | static int getTwinPrime(int inputNumber) { FILE: src/main/java/com/thealgorithms/maths/UniformNumbers.java class UniformNumbers (line 10) | public final class UniformNumbers { method UniformNumbers (line 12) | private UniformNumbers() { method uniformNumbers (line 21) | public static int uniformNumbers(int num) { method countUniformIntegers (line 41) | public static int countUniformIntegers(int a, int b) { FILE: src/main/java/com/thealgorithms/maths/VampireNumber.java class VampireNumber (line 15) | public final class VampireNumber { method VampireNumber (line 17) | private VampireNumber() { method isVampireNumber (line 20) | static boolean isVampireNumber(int a, int b, boolean ignorePseudoVampi... method splitIntoSortedDigits (line 33) | static String splitIntoSortedDigits(int... nums) { FILE: src/main/java/com/thealgorithms/maths/VectorCrossProduct.java class VectorCrossProduct (line 42) | public class VectorCrossProduct { method VectorCrossProduct (line 49) | VectorCrossProduct() { method VectorCrossProduct (line 62) | VectorCrossProduct(int vectorX, int vectorY, int vectorZ) { method magnitude (line 73) | double magnitude() { method dotProduct (line 83) | int dotProduct(VectorCrossProduct b) { method crossProduct (line 93) | VectorCrossProduct crossProduct(VectorCrossProduct b) { method displayVector (line 104) | void displayVector() { method main (line 108) | public static void main(String[] args) { method test (line 112) | static void test() { FILE: src/main/java/com/thealgorithms/maths/Volume.java class Volume (line 4) | public final class Volume { method Volume (line 5) | private Volume() { method volumeCube (line 14) | public static double volumeCube(double sideLength) { method volumeCuboid (line 26) | public static double volumeCuboid(double width, double height, double ... method volumeSphere (line 36) | public static double volumeSphere(double radius) { method volumeCylinder (line 47) | public static double volumeCylinder(double radius, double height) { method volumeHemisphere (line 57) | public static double volumeHemisphere(double radius) { method volumeCone (line 68) | public static double volumeCone(double radius, double height) { method volumePrism (line 79) | public static double volumePrism(double baseArea, double height) { method volumePyramid (line 90) | public static double volumePyramid(double baseArea, double height) { method volumeFrustumOfCone (line 102) | public static double volumeFrustumOfCone(double r1, double r2, double ... method volumeFrustumOfPyramid (line 114) | public static double volumeFrustumOfPyramid(double upperBaseArea, doub... method volumeTorus (line 125) | public static double volumeTorus(double majorRadius, double minorRadiu... FILE: src/main/java/com/thealgorithms/maths/ZellersCongruence.java class ZellersCongruence (line 18) | public final class ZellersCongruence { method ZellersCongruence (line 23) | private ZellersCongruence() { method calculateDay (line 37) | public static String calculateDay(String input) { method parsePart (line 84) | private static int parsePart(String part, int min, int max, String err... method validateSeparator (line 102) | private static void validateSeparator(char sep) { FILE: src/main/java/com/thealgorithms/matrix/InverseOfMatrix.java class InverseOfMatrix (line 8) | public final class InverseOfMatrix { method InverseOfMatrix (line 9) | private InverseOfMatrix() { method invert (line 12) | public static double[][] invert(double[][] a) { method gaussian (line 52) | private static void gaussian(double[][] a, int[] index) { FILE: src/main/java/com/thealgorithms/matrix/LUDecomposition.java class LUDecomposition (line 15) | public final class LUDecomposition { method LUDecomposition (line 17) | private LUDecomposition() { class LU (line 23) | public static class LU { method LU (line 27) | LU(double[][] l, double[][] u) { method decompose (line 39) | public static LU decompose(double[][] a) { method printMatrix (line 76) | public static void printMatrix(double[][] m) { FILE: src/main/java/com/thealgorithms/matrix/MatrixMultiplication.java class MatrixMultiplication (line 24) | public final class MatrixMultiplication { method MatrixMultiplication (line 25) | private MatrixMultiplication() { method multiply (line 36) | public static double[][] multiply(double[][] matrixA, double[][] matri... FILE: src/main/java/com/thealgorithms/matrix/MatrixRank.java class MatrixRank (line 18) | public final class MatrixRank { method MatrixRank (line 20) | private MatrixRank() { method computeRank (line 31) | public static int computeRank(double[][] matrix) { method isZero (line 54) | private static boolean isZero(double value) { method deepCopy (line 58) | private static double[][] deepCopy(double[][] matrix) { method findPivotRow (line 80) | private static int findPivotRow(double[][] matrix, boolean[] rowMarked... method normalizePivotRow (line 98) | private static void normalizePivotRow(double[][] matrix, int pivotRow,... method eliminateRows (line 114) | private static void eliminateRows(double[][] matrix, int pivotRow, int... FILE: src/main/java/com/thealgorithms/matrix/MatrixTranspose.java class MatrixTranspose (line 19) | public final class MatrixTranspose { method MatrixTranspose (line 20) | private MatrixTranspose() { method transpose (line 31) | public static int[][] transpose(int[][] matrix) { FILE: src/main/java/com/thealgorithms/matrix/MedianOfMatrix.java class MedianOfMatrix (line 12) | public final class MedianOfMatrix { method MedianOfMatrix (line 13) | private MedianOfMatrix() { method median (line 16) | public static int median(Iterable> matrix) { FILE: src/main/java/com/thealgorithms/matrix/MirrorOfMatrix.java class MirrorOfMatrix (line 19) | public final class MirrorOfMatrix { method MirrorOfMatrix (line 20) | private MirrorOfMatrix() { method mirrorMatrix (line 23) | public static double[][] mirrorMatrix(final double[][] originalMatrix) { FILE: src/main/java/com/thealgorithms/matrix/PrintAMatrixInSpiralOrder.java class PrintAMatrixInSpiralOrder (line 17) | public class PrintAMatrixInSpiralOrder { method print (line 40) | public List print(int[][] matrix, int row, int col) { FILE: src/main/java/com/thealgorithms/matrix/RotateMatrixBy90Degrees.java class RotateMatrixBy90Degrees (line 8) | final class RotateMatrixBy90Degrees { method RotateMatrixBy90Degrees (line 9) | private RotateMatrixBy90Degrees() { method main (line 12) | public static void main(String[] args) { method printMatrix (line 32) | static void printMatrix(int[][] arr) { class Rotate (line 45) | final class Rotate { method Rotate (line 46) | private Rotate() { method rotate (line 49) | static void rotate(int[][] a) { FILE: src/main/java/com/thealgorithms/matrix/SolveSystem.java class SolveSystem (line 9) | public final class SolveSystem { method SolveSystem (line 10) | private SolveSystem() { method solveSystem (line 22) | public static double[] solveSystem(double[][] matrix, double[] constan... FILE: src/main/java/com/thealgorithms/matrix/StochasticMatrix.java class StochasticMatrix (line 9) | public final class StochasticMatrix { method StochasticMatrix (line 13) | private StochasticMatrix() { method isRowStochastic (line 23) | public static boolean isRowStochastic(double[][] matrix) { method isColumnStochastic (line 48) | public static boolean isColumnStochastic(double[][] matrix) { method validateMatrix (line 69) | private static void validateMatrix(double[][] matrix) { FILE: src/main/java/com/thealgorithms/matrix/matrixexponentiation/Fibonacci.java class Fibonacci (line 11) | public final class Fibonacci { method Fibonacci (line 12) | private Fibonacci() { method fib (line 29) | public static BigDecimal[][] fib(int n) { FILE: src/main/java/com/thealgorithms/matrix/utils/MatrixUtil.java class MatrixUtil (line 12) | public final class MatrixUtil { method MatrixUtil (line 14) | private MatrixUtil() { method isValid (line 17) | private static boolean isValid(final BigDecimal[][] matrix) { method hasEqualSizes (line 21) | private static boolean hasEqualSizes(final BigDecimal[][] matrix1, fin... method canMultiply (line 25) | private static boolean canMultiply(final BigDecimal[][] matrix1, final... method validateInputMatrix (line 29) | public static void validateInputMatrix(double[][] matrix) { method hasValidRows (line 44) | private static boolean hasValidRows(double[][] matrix) { method isJaggedMatrix (line 60) | private static boolean isJaggedMatrix(double[][] matrix) { method operate (line 70) | private static Optional operate(final BigDecimal[][] m... method add (line 90) | public static Optional add(final BigDecimal[][] matrix... method subtract (line 94) | public static Optional subtract(final BigDecimal[][] m... method multiply (line 98) | public static Optional multiply(final BigDecimal[][] m... method reverseRow (line 126) | public static double[] reverseRow(final double[] inRow) { FILE: src/main/java/com/thealgorithms/misc/ColorContrastRatio.java class ColorContrastRatio (line 13) | public class ColorContrastRatio { method getContrastRatio (line 21) | public double getContrastRatio(Color a, Color b) { method getRelativeLuminance (line 38) | public double getRelativeLuminance(Color color) { method getColor (line 51) | public double getColor(int color8Bit) { method getColorSRgb (line 61) | private double getColorSRgb(double color8Bit) { FILE: src/main/java/com/thealgorithms/misc/MapReduce.java class MapReduce (line 19) | public final class MapReduce { method MapReduce (line 21) | private MapReduce() { method countWordFrequencies (line 30) | public static String countWordFrequencies(String sentence) { FILE: src/main/java/com/thealgorithms/misc/MedianOfRunningArray.java class MedianOfRunningArray (line 14) | public abstract class MedianOfRunningArray generatePalindromePrimes(int n) { FILE: src/main/java/com/thealgorithms/misc/PalindromeSinglyLinkedList.java class PalindromeSinglyLinkedList (line 13) | @SuppressWarnings("rawtypes") method PalindromeSinglyLinkedList (line 15) | private PalindromeSinglyLinkedList() { method isPalindrome (line 18) | public static boolean isPalindrome(final Iterable linkedList) { method isPalindromeOptimised (line 36) | public static boolean isPalindromeOptimised(Node head) { class Node (line 68) | static class Node { method Node (line 71) | Node(int val) { FILE: src/main/java/com/thealgorithms/misc/RangeInSortedArray.java class RangeInSortedArray (line 7) | public final class RangeInSortedArray { method RangeInSortedArray (line 9) | private RangeInSortedArray() { method sortedRange (line 22) | public static int[] sortedRange(int[] nums, int key) { method alteredBinSearch (line 39) | public static void alteredBinSearch(int[] nums, int key, int left, int... method alteredBinSearchIter (line 75) | public static void alteredBinSearchIter(int[] nums, int key, int left,... method getCountLessThan (line 107) | public static int getCountLessThan(int[] nums, int key) { method getLessThan (line 120) | public static int getLessThan(int[] nums, int key, int left, int right) { FILE: src/main/java/com/thealgorithms/misc/ShuffleArray.java class ShuffleArray (line 19) | public final class ShuffleArray { method ShuffleArray (line 21) | private ShuffleArray() { method shuffle (line 30) | public static void shuffle(int[] arr) { method swap (line 49) | private static void swap(int[] arr, int i, int j) { FILE: src/main/java/com/thealgorithms/misc/Sparsity.java class Sparsity (line 13) | public final class Sparsity { method Sparsity (line 15) | private Sparsity() { method sparsity (line 25) | public static double sparsity(double[][] matrix) { FILE: src/main/java/com/thealgorithms/misc/ThreeSumProblem.java class ThreeSumProblem (line 12) | public class ThreeSumProblem { method bruteForce (line 14) | public List> bruteForce(int[] nums, int target) { method twoPointer (line 35) | public List> twoPointer(int[] nums, int target) { method hashMap (line 65) | public List> hashMap(int[] nums, int target) { FILE: src/main/java/com/thealgorithms/misc/TwoSumProblem.java class TwoSumProblem (line 7) | public final class TwoSumProblem { method TwoSumProblem (line 8) | private TwoSumProblem() { method twoSum (line 20) | public static Optional> twoSum(final int[] valu... FILE: src/main/java/com/thealgorithms/others/ArrayLeftRotation.java class ArrayLeftRotation (line 10) | public final class ArrayLeftRotation { method ArrayLeftRotation (line 11) | private ArrayLeftRotation() { method rotateLeft (line 21) | public static int[] rotateLeft(int[] arr, int n) { FILE: src/main/java/com/thealgorithms/others/ArrayRightRotation.java class ArrayRightRotation (line 10) | public final class ArrayRightRotation { method ArrayRightRotation (line 11) | private ArrayRightRotation() { method rotateRight (line 21) | public static int[] rotateRight(int[] arr, int k) { method reverseArray (line 42) | private static void reverseArray(int[] arr, int start, int end) { FILE: src/main/java/com/thealgorithms/others/BFPRT.java class BFPRT (line 9) | public final class BFPRT { method BFPRT (line 10) | private BFPRT() { method getMinKNumsByBFPRT (line 20) | public static int[] getMinKNumsByBFPRT(int[] arr, int k) { method getMinKthByBFPRT (line 45) | public static int getMinKthByBFPRT(int[] arr, int k) { method copyArray (line 56) | public static int[] copyArray(int[] arr) { method bfprt (line 71) | public static int bfprt(int[] arr, int begin, int end, int i) { method medianOfMedians (line 94) | public static int medianOfMedians(int[] arr, int begin, int end) { method partition (line 113) | public static int[] partition(int[] arr, int begin, int end, int num) { method getMedian (line 137) | public static int getMedian(int[] arr, int begin, int end) { method insertionSort (line 151) | public static void insertionSort(int[] arr, int begin, int end) { method swap (line 173) | public static void swap(int[] arr, int i, int j) { FILE: src/main/java/com/thealgorithms/others/BankersAlgorithm.java class BankersAlgorithm (line 23) | public final class BankersAlgorithm { method BankersAlgorithm (line 24) | private BankersAlgorithm() { method calculateNeed (line 30) | static void calculateNeed(int[][] needArray, int[][] maxArray, int[][]... method checkSafeSystem (line 53) | static boolean checkSafeSystem(int[] processes, int[] availableArray, ... method main (line 112) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/others/BoyerMoore.java class BoyerMoore (line 12) | public final class BoyerMoore { method BoyerMoore (line 13) | private BoyerMoore() { method findMajorityElement (line 22) | public static Optional findMajorityElement(int[] array) { method findCandidate (line 42) | private static int findCandidate(final int[] array) { method countOccurrences (line 61) | private static int countOccurrences(final int candidate, final int[] a... method isMajority (line 78) | private static boolean isMajority(int count, int totalCount) { FILE: src/main/java/com/thealgorithms/others/BrianKernighanAlgorithm.java class BrianKernighanAlgorithm (line 23) | public final class BrianKernighanAlgorithm { method BrianKernighanAlgorithm (line 24) | private BrianKernighanAlgorithm() { method countSetBits (line 31) | static int countSetBits(int num) { method main (line 43) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/others/CRC16.java class CRC16 (line 6) | public final class CRC16 { method CRC16 (line 7) | private CRC16() { method main (line 10) | public static void main(String[] args) { method crc16 (line 14) | public static String crc16(String message) { FILE: src/main/java/com/thealgorithms/others/CRC32.java class CRC32 (line 8) | public final class CRC32 { method CRC32 (line 9) | private CRC32() { method main (line 12) | public static void main(String[] args) { method crc32 (line 16) | public static int crc32(String str) { method crc32 (line 20) | public static int crc32(byte[] data) { FILE: src/main/java/com/thealgorithms/others/CRCAlgorithm.java class CRCAlgorithm (line 10) | @SuppressWarnings("unchecked") method CRCAlgorithm (line 42) | public CRCAlgorithm(String str, int size, double ber) { method getWrongMess (line 63) | public int getWrongMess() { method getWrongMessCaught (line 73) | public int getWrongMessCaught() { method getWrongMessNotCaught (line 83) | public int getWrongMessNotCaught() { method getCorrectMess (line 92) | public int getCorrectMess() { method refactor (line 101) | public void refactor() { method generateRandomMess (line 110) | public void generateRandomMess() { method divideMessageWithP (line 130) | public void divideMessageWithP(boolean check) { method changeMess (line 179) | public void changeMess() { FILE: src/main/java/com/thealgorithms/others/Conway.java class Conway (line 7) | public final class Conway { method Conway (line 8) | private Conway() { method generateList (line 22) | protected static List generateList(String originalString, int ... method generateNextElement (line 31) | public static String generateNextElement(String originalString) { FILE: src/main/java/com/thealgorithms/others/Damm.java class Damm (line 17) | public final class Damm { method Damm (line 18) | private Damm() { method dammCheck (line 50) | public static boolean dammCheck(String digits) { method addDammChecksum (line 72) | public static String addDammChecksum(String initialDigits) { method main (line 84) | public static void main(String[] args) { method checkAndPrint (line 96) | private static void checkAndPrint(String input) { method generateAndPrint (line 101) | private static void generateAndPrint(String input) { method checkInput (line 106) | private static void checkInput(String input) { method toIntArray (line 113) | private static int[] toIntArray(String string) { FILE: src/main/java/com/thealgorithms/others/Dijkstra.java class Dijkstra (line 22) | public final class Dijkstra { method Dijkstra (line 23) | private Dijkstra() { method main (line 46) | public static void main(String[] args) { class Graph (line 54) | class Graph { class Edge (line 63) | public static class Edge { method Edge (line 69) | Edge(String v1, String v2, int dist) { class Vertex (line 79) | public static class Vertex implements Comparable { method Vertex (line 87) | Vertex(String name) { method printPath (line 91) | private void printPath() { method compareTo (line 102) | public int compareTo(Vertex other) { method equals (line 110) | @Override method hashCode (line 136) | @Override method toString (line 146) | @Override method Graph (line 155) | Graph(Edge[] edges) { method dijkstra (line 179) | public void dijkstra(String startName) { method dijkstra (line 200) | private void dijkstra(final NavigableSet q) { method printPath (line 228) | public void printPath(String endName) { method printAllPaths (line 242) | public void printAllPaths() { FILE: src/main/java/com/thealgorithms/others/FloydTriangle.java class FloydTriangle (line 6) | final class FloydTriangle { method FloydTriangle (line 7) | private FloydTriangle() { method generateFloydTriangle (line 16) | public static List> generateFloydTriangle(int rows) { FILE: src/main/java/com/thealgorithms/others/GaussLegendre.java class GaussLegendre (line 9) | public final class GaussLegendre { method GaussLegendre (line 10) | private GaussLegendre() { method main (line 13) | public static void main(String[] args) { method pi (line 19) | static double pi(int l) { method update (line 39) | static double[] update(double a, double b, double t, double p) { FILE: src/main/java/com/thealgorithms/others/Huffman.java class HuffmanNode (line 13) | class HuffmanNode { method HuffmanNode (line 25) | HuffmanNode(char c, int data) { method HuffmanNode (line 35) | HuffmanNode() { class HuffmanComparator (line 46) | class HuffmanComparator implements Comparator { method compare (line 47) | @Override class Huffman (line 67) | public final class Huffman { method Huffman (line 68) | private Huffman() { method buildHuffmanTree (line 80) | public static HuffmanNode buildHuffmanTree(char[] charArray, int[] cha... method generateCodes (line 126) | public static Map generateCodes(HuffmanNode root) { method generateCodesHelper (line 141) | private static void generateCodesHelper(HuffmanNode node, String code,... method printCode (line 168) | public static void printCode(HuffmanNode root, String code) { method main (line 193) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/others/Implementing_auto_completing_features_using_trie.java class Trieac (line 5) | class Trieac { class TrieNode (line 11) | static class TrieNode { method getNode (line 21) | static TrieNode getNode() { method insert (line 34) | static void insert(TrieNode root, final String key) { method search (line 50) | boolean search(TrieNode root, final String key) { method isLastNode (line 67) | static boolean isLastNode(TrieNode root) { method suggestionsRec (line 78) | static void suggestionsRec(TrieNode root, String currPrefix) { method printAutoSuggestions (line 102) | static int printAutoSuggestions(TrieNode root, final String query) { method main (line 149) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/others/InsertDeleteInArray.java class InsertDeleteInArray (line 35) | public final class InsertDeleteInArray { method InsertDeleteInArray (line 36) | private InsertDeleteInArray() { method insertElement (line 55) | public static int[] insertElement(int[] array, int element, int positi... method deleteElement (line 91) | public static int[] deleteElement(int[] array, int position) { method main (line 127) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/others/IterativeFloodFill.java class IterativeFloodFill (line 27) | public final class IterativeFloodFill { method IterativeFloodFill (line 28) | private IterativeFloodFill() { method floodFill (line 41) | public static void floodFill(final int[][] image, final int x, final i... class Point (line 75) | private static class Point { method Point (line 79) | Point(final int x, final int y) { method shouldSkipPixel (line 94) | private static boolean shouldSkipPixel(final int[][] image, final int ... FILE: src/main/java/com/thealgorithms/others/KochSnowflake.java class KochSnowflake (line 28) | public final class KochSnowflake { method KochSnowflake (line 29) | private KochSnowflake() { method main (line 32) | public static void main(String[] args) { method iterate (line 84) | public static ArrayList iterate(ArrayList initialVec... method getKochSnowflake (line 100) | public static BufferedImage getKochSnowflake(int imageWidth, int steps) { method iterationStep (line 129) | private static ArrayList iterationStep(List vectors) { method getImage (line 153) | private static BufferedImage getImage(ArrayList vectors, int ... class Vector2 (line 180) | private static class Vector2 { method Vector2 (line 185) | Vector2(double x, double y) { method toString (line 190) | @Override method add (line 201) | public Vector2 add(Vector2 vector) { method subtract (line 213) | public Vector2 subtract(Vector2 vector) { method multiply (line 225) | public Vector2 multiply(double scalar) { method rotate (line 237) | public Vector2 rotate(double angleInDegrees) { FILE: src/main/java/com/thealgorithms/others/LineSweep.java class LineSweep (line 18) | public final class LineSweep { method LineSweep (line 19) | private LineSweep() { method findMaximumEndPoint (line 28) | public static int findMaximumEndPoint(int[][] ranges) { method isOverlap (line 39) | public static boolean isOverlap(int[][] ranges) { FILE: src/main/java/com/thealgorithms/others/LinearCongruentialGenerator.java class LinearCongruentialGenerator (line 10) | public class LinearCongruentialGenerator { method LinearCongruentialGenerator (line 27) | public LinearCongruentialGenerator(double multiplier, double increment... method LinearCongruentialGenerator (line 41) | public LinearCongruentialGenerator(double seed, double multiplier, dou... method nextNumber (line 54) | public double nextNumber() { method main (line 59) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/others/LowestBasePalindrome.java class LowestBasePalindrome (line 28) | public final class LowestBasePalindrome { method LowestBasePalindrome (line 29) | private LowestBasePalindrome() { method checkBase (line 38) | private static void checkBase(int base) { method checkNumber (line 50) | private static void checkNumber(int number) { method computeDigitsInBase (line 71) | public static List computeDigitsInBase(int number, int base) { method isPalindromic (line 93) | public static boolean isPalindromic(List list) { method isPalindromicInBase (line 128) | public static boolean isPalindromicInBase(int number, int base) { method lowestBasePalindrome (line 171) | public static int lowestBasePalindrome(int number) { FILE: src/main/java/com/thealgorithms/others/Luhn.java class Luhn (line 41) | public final class Luhn { method Luhn (line 42) | private Luhn() { method luhnCheck (line 52) | public static boolean luhnCheck(int[] digits) { method main (line 70) | public static void main(String[] args) { method checkAndPrint (line 87) | private static void checkAndPrint(int[] input) { method fromString (line 110) | public static CreditCard fromString(String cardNumber) { method number (line 130) | public String number() { method toString (line 141) | @Override method toIntArray (line 146) | private static int[] toIntArray(String string) { method businessExample (line 151) | private static void businessExample(String cardNumber) { FILE: src/main/java/com/thealgorithms/others/Mandelbrot.java class Mandelbrot (line 26) | public final class Mandelbrot { method Mandelbrot (line 27) | private Mandelbrot() { method main (line 30) | public static void main(String[] args) { method getImage (line 75) | public static BufferedImage getImage(int imageWidth, int imageHeight, ... method blackAndWhiteColorMap (line 115) | private static Color blackAndWhiteColorMap(double distance) { method colorCodedColorMap (line 126) | private static Color colorCodedColorMap(double distance) { method getDistance (line 170) | private static double getDistance(double figureX, double figureY, int ... FILE: src/main/java/com/thealgorithms/others/MaximumSumOfDistinctSubarraysWithLengthK.java class MaximumSumOfDistinctSubarraysWithLengthK (line 26) | public final class MaximumSumOfDistinctSubarraysWithLengthK { method MaximumSumOfDistinctSubarraysWithLengthK (line 27) | private MaximumSumOfDistinctSubarraysWithLengthK() { method maximumSubarraySum (line 44) | public static long maximumSubarraySum(int k, int... nums) { FILE: src/main/java/com/thealgorithms/others/MemoryManagementAlgorithms.java class MemoryManagementAlgorithms (line 7) | public abstract class MemoryManagementAlgorithms { method fitProcess (line 22) | public abstract ArrayList fitProcess(int[] sizeOfBlocks, int[... class BestFitCPU (line 41) | class BestFitCPU extends MemoryManagementAlgorithms { method findMaxElement (line 50) | private static int findMaxElement(int[] array) { method findBestFit (line 69) | private static int findBestFit(int[] blockSizes, int processSize) { method fitProcess (line 97) | public ArrayList fitProcess(int[] sizeOfBlocks, int[] sizeOfP... class WorstFitCPU (line 116) | class WorstFitCPU extends MemoryManagementAlgorithms { method findWorstFit (line 127) | private static int findWorstFit(int[] blockSizes, int processSize) { method fitProcess (line 155) | public ArrayList fitProcess(int[] sizeOfBlocks, int[] sizeOfP... class FirstFitCPU (line 174) | class FirstFitCPU extends MemoryManagementAlgorithms { method findFirstFit (line 185) | private static int findFirstFit(int[] blockSizes, int processSize) { method fitProcess (line 207) | public ArrayList fitProcess(int[] sizeOfBlocks, int[] sizeOfP... class NextFit (line 226) | class NextFit extends MemoryManagementAlgorithms { method findNextFit (line 241) | private int findNextFit(int[] blockSizes, int processSize) { method fitProcess (line 268) | public ArrayList fitProcess(int[] sizeOfBlocks, int[] sizeOfP... FILE: src/main/java/com/thealgorithms/others/MiniMaxAlgorithm.java class MiniMaxAlgorithm (line 32) | public final class MiniMaxAlgorithm { method MiniMaxAlgorithm (line 51) | public MiniMaxAlgorithm() { method MiniMaxAlgorithm (line 63) | public MiniMaxAlgorithm(int[] scores) { method main (line 76) | public static void main(String[] args) { method miniMax (line 102) | public int miniMax(int depth, boolean isMaximizer, int index, boolean ... method getRandomScores (line 143) | public static int[] getRandomScores(int size, int maxScore) { method log2 (line 159) | private int log2(int n) { method isPowerOfTwo (line 169) | private boolean isPowerOfTwo(int n) { method setScores (line 180) | public void setScores(int[] scores) { method getScores (line 193) | public int[] getScores() { method getHeight (line 202) | public int getHeight() { FILE: src/main/java/com/thealgorithms/others/MosAlgorithm.java class MosAlgorithm (line 20) | public final class MosAlgorithm { class Query (line 25) | public static class Query { method Query (line 31) | public Query(int left, int right, int index) { method MosAlgorithm (line 39) | private MosAlgorithm() { method solveRangeSumQueries (line 50) | public static int[] solveRangeSumQueries(int[] arr, Query[] queries) { method solveRangeFrequencyQueries (line 116) | public static int[] solveRangeFrequencyQueries(int[] arr, Query[] quer... class MoComparator (line 183) | private static class MoComparator implements Comparator { method MoComparator (line 186) | MoComparator(int blockSize) { method compare (line 190) | @Override method main (line 214) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/others/PageRank.java class PageRank (line 27) | public final class PageRank { method PageRank (line 44) | public PageRank(int numberOfNodes) { method PageRank (line 56) | public PageRank() { method main (line 66) | public static void main(String[] args) { method setEdge (line 92) | public void setEdge(int from, int to, int value) { method setAdjacencyMatrix (line 105) | public void setAdjacencyMatrix(int[][] matrix) { method getPageRank (line 119) | public double getPageRank(int node) { method getAllPageRanks (line 131) | public double[] getAllPageRanks() { method calculatePageRank (line 141) | public double[] calculatePageRank(int totalNodes) { method calculatePageRank (line 154) | public double[] calculatePageRank(int totalNodes, double dampingFactor... method validateInputParameters (line 183) | private void validateInputParameters(int totalNodes, double dampingFac... method initializePageRanks (line 202) | private void initializePageRanks(int totalNodes, double initialPageRan... method performIterations (line 221) | private void performIterations(int totalNodes, double dampingFactor, i... method storeCurrentPageRanks (line 240) | private double[] storeCurrentPageRanks(int totalNodes) { method calculateNewPageRanks (line 255) | private void calculateNewPageRanks(int totalNodes, double[] tempPageRa... method applyDampingFactor (line 274) | private void applyDampingFactor(int totalNodes, double dampingFactor) { method countOutgoingLinks (line 287) | private int countOutgoingLinks(int node, int totalNodes) { method printPageRanks (line 302) | private void printPageRanks(int totalNodes) { FILE: src/main/java/com/thealgorithms/others/PasswordGen.java class PasswordGen (line 14) | final class PasswordGen { method PasswordGen (line 21) | private PasswordGen() { method generatePassword (line 32) | public static String generatePassword(int minLength, int maxLength) { FILE: src/main/java/com/thealgorithms/others/PerlinNoise.java class PerlinNoise (line 38) | public final class PerlinNoise { method PerlinNoise (line 39) | private PerlinNoise() { method generatePerlinNoise (line 53) | static float[][] generatePerlinNoise(int width, int height, int octave... method createBaseGrid (line 70) | static float[][] createBaseGrid(int width, int height, long seed) { method createLayers (line 82) | static float[][][] createLayers(float[][] base, int width, int height,... method blendAndNormalize (line 91) | static float[][] blendAndNormalize(float[][][] layers, int width, int ... method generatePerlinNoiseLayer (line 131) | static float[][] generatePerlinNoiseLayer(float[][] base, int width, i... method interpolate (line 172) | static float interpolate(float a, float b, float alpha) { method main (line 180) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/others/QueueUsingTwoStacks.java class QueueUsingTwoStacks (line 18) | public class QueueUsingTwoStacks { method QueueUsingTwoStacks (line 25) | public QueueUsingTwoStacks() { method insert (line 35) | public void insert(Object x) { method remove (line 45) | public Object remove() { method peekFront (line 60) | public Object peekFront() { method peekBack (line 75) | public Object peekBack() { method isEmpty (line 84) | public boolean isEmpty() { method isInStackEmpty (line 93) | public boolean isInStackEmpty() { method isOutStackEmpty (line 102) | public boolean isOutStackEmpty() { FILE: src/main/java/com/thealgorithms/others/SkylineProblem.java class SkylineProblem (line 11) | public class SkylineProblem { method add (line 24) | public void add(int left, int height, int right) { method findSkyline (line 36) | public ArrayList findSkyline(int start, int end) { method mergeSkyline (line 59) | public ArrayList mergeSkyline(ArrayList sky1, ArrayL... class Skyline (line 115) | public class Skyline { method Skyline (line 125) | public Skyline(int coordinates, int height) { class Building (line 135) | public class Building { method Building (line 147) | public Building(int left, int height, int right) { FILE: src/main/java/com/thealgorithms/others/TwoPointers.java class TwoPointers (line 10) | public final class TwoPointers { method TwoPointers (line 12) | private TwoPointers() { method isPairedSum (line 23) | public static boolean isPairedSum(int[] arr, int key) { FILE: src/main/java/com/thealgorithms/others/Verhoeff.java class Verhoeff (line 26) | public final class Verhoeff { method Verhoeff (line 27) | private Verhoeff() { method verhoeffCheck (line 95) | public static boolean verhoeffCheck(String digits) { method addVerhoeffChecksum (line 120) | public static String addVerhoeffChecksum(String initialDigits) { method main (line 139) | public static void main(String[] args) { method checkAndPrint (line 151) | private static void checkAndPrint(String input) { method generateAndPrint (line 156) | private static void generateAndPrint(String input) { method checkInput (line 161) | private static void checkInput(String input) { method toIntArray (line 168) | private static int[] toIntArray(String string) { FILE: src/main/java/com/thealgorithms/physics/CoulombsLaw.java class CoulombsLaw (line 10) | public final class CoulombsLaw { method CoulombsLaw (line 18) | private CoulombsLaw() { method calculateForceVector (line 33) | public static double[] calculateForceVector(double q1, double x1, doub... method calculateCircularOrbitVelocity (line 69) | public static double calculateCircularOrbitVelocity(double centralChar... FILE: src/main/java/com/thealgorithms/physics/DampedOscillator.java class DampedOscillator (line 29) | public final class DampedOscillator { method DampedOscillator (line 37) | private DampedOscillator() { method DampedOscillator (line 48) | public DampedOscillator(double omega0, double gamma) { method displacementAnalytical (line 68) | public double displacementAnalytical(double amplitude, double phase, d... method stepEuler (line 82) | public double[] stepEuler(double[] state, double dt) { method getOmega0 (line 101) | public double getOmega0() { method getGamma (line 106) | public double getGamma() { FILE: src/main/java/com/thealgorithms/physics/ElasticCollision2D.java class ElasticCollision2D (line 9) | public final class ElasticCollision2D { method ElasticCollision2D (line 11) | private ElasticCollision2D() { class Body (line 15) | public static class Body { method Body (line 23) | public Body(double x, double y, double vx, double vy, double mass, d... method resolveCollision (line 39) | public static void resolveCollision(Body a, Body b) { FILE: src/main/java/com/thealgorithms/physics/Gravitation.java class Gravitation (line 10) | public final class Gravitation { method Gravitation (line 18) | private Gravitation() { method calculateGravitationalForce (line 32) | public static double[] calculateGravitationalForce(double m1, double x... method calculateCircularOrbitVelocity (line 60) | public static double calculateCircularOrbitVelocity(double centralMass... FILE: src/main/java/com/thealgorithms/physics/GroundToGroundProjectileMotion.java class GroundToGroundProjectileMotion (line 11) | public final class GroundToGroundProjectileMotion { method GroundToGroundProjectileMotion (line 13) | private GroundToGroundProjectileMotion() { method degreesToRadians (line 26) | private static double degreesToRadians(double degrees) { method timeOfFlight (line 37) | public static double timeOfFlight(double initialVelocity, double angle) { method timeOfFlight (line 49) | public static double timeOfFlight(double initialVelocity, double angle... method horizontalRange (line 62) | public static double horizontalRange(double initialVelocity, double an... method maxHeight (line 74) | public static double maxHeight(double initialVelocity, double angle) { method maxHeight (line 86) | public static double maxHeight(double initialVelocity, double angle, d... FILE: src/main/java/com/thealgorithms/physics/Kinematics.java class Kinematics (line 9) | public final class Kinematics { method Kinematics (line 10) | private Kinematics() { method calculateFinalVelocity (line 23) | public static double calculateFinalVelocity(double u, double a, double... method calculateDisplacement (line 37) | public static double calculateDisplacement(double u, double a, double ... method calculateFinalVelocitySquared (line 51) | public static double calculateFinalVelocitySquared(double u, double a,... method calculateDisplacementFromVelocities (line 65) | public static double calculateDisplacementFromVelocities(double u, dou... FILE: src/main/java/com/thealgorithms/physics/ProjectileMotion.java class ProjectileMotion (line 11) | public final class ProjectileMotion { method ProjectileMotion (line 13) | private ProjectileMotion() { class Result (line 22) | public static final class Result { method Result (line 27) | public Result(double timeOfFlight, double horizontalRange, double ma... method getTimeOfFlight (line 34) | public double getTimeOfFlight() { method getHorizontalRange (line 39) | public double getHorizontalRange() { method getMaxHeight (line 44) | public double getMaxHeight() { method calculateTrajectory (line 57) | public static Result calculateTrajectory(double initialVelocity, doubl... method calculateTrajectory (line 70) | public static Result calculateTrajectory(double initialVelocity, doubl... FILE: src/main/java/com/thealgorithms/physics/SimplePendulumRK4.java class SimplePendulumRK4 (line 9) | public final class SimplePendulumRK4 { method SimplePendulumRK4 (line 11) | private SimplePendulumRK4() { method SimplePendulumRK4 (line 24) | public SimplePendulumRK4(double length, double g) { method derivatives (line 42) | private double[] derivatives(double[] state) { method stepRK4 (line 57) | public double[] stepRK4(double[] state, double dt) { method simulate (line 90) | public double[][] simulate(double[] initialState, double dt, int steps) { method calculateEnergy (line 111) | public double calculateEnergy(double[] state) { method getLength (line 119) | public double getLength() { method getGravity (line 123) | public double getGravity() { FILE: src/main/java/com/thealgorithms/physics/SnellLaw.java class SnellLaw (line 8) | public final class SnellLaw { method SnellLaw (line 10) | private SnellLaw() { method refractedAngle (line 23) | public static double refractedAngle(double n1, double n2, double theta... FILE: src/main/java/com/thealgorithms/physics/ThinLens.java class ThinLens (line 21) | public final class ThinLens { method ThinLens (line 23) | private ThinLens() { method imageDistance (line 35) | public static double imageDistance(double focalLength, double objectDi... method magnification (line 56) | public static double magnification(double imageDistance, double object... method isRealImage (line 71) | public static boolean isRealImage(double imageDistance) { FILE: src/main/java/com/thealgorithms/prefixsum/DifferenceArray.java class DifferenceArray (line 23) | public class DifferenceArray { method DifferenceArray (line 34) | public DifferenceArray(int[] inputArray) { method initializeDifferenceArray (line 44) | private void initializeDifferenceArray(int[] inputArray) { method update (line 64) | public void update(int l, int r, int val) { method getResultArray (line 78) | public long[] getResultArray() { FILE: src/main/java/com/thealgorithms/prefixsum/PrefixSum.java class PrefixSum (line 16) | public class PrefixSum { method PrefixSum (line 26) | public PrefixSum(int[] array) { method sumRange (line 48) | public long sumRange(int left, int right) { FILE: src/main/java/com/thealgorithms/prefixsum/PrefixSum2D.java class PrefixSum2D (line 16) | public class PrefixSum2D { method PrefixSum2D (line 26) | public PrefixSum2D(int[][] matrix) { method sumRegion (line 54) | public long sumRegion(int row1, int col1, int row2, int col2) { FILE: src/main/java/com/thealgorithms/prefixsum/RangeSumQuery.java class RangeSumQuery (line 28) | public final class RangeSumQuery { method RangeSumQuery (line 30) | private RangeSumQuery() { method buildPrefixSum (line 41) | public static int[] buildPrefixSum(int[] nums) { method sumRange (line 64) | public static int sumRange(int[] prefixSum, int left, int right) { FILE: src/main/java/com/thealgorithms/prefixsum/SubarraySumEqualsK.java class SubarraySumEqualsK (line 36) | public final class SubarraySumEqualsK { method SubarraySumEqualsK (line 38) | private SubarraySumEqualsK() { method countSubarrays (line 50) | public static int countSubarrays(int[] nums, int k) { FILE: src/main/java/com/thealgorithms/puzzlesandgames/TowerOfHanoi.java class TowerOfHanoi (line 31) | public final class TowerOfHanoi { method TowerOfHanoi (line 33) | private TowerOfHanoi() { method shift (line 59) | public static void shift(int n, String startPole, String intermediateP... FILE: src/main/java/com/thealgorithms/puzzlesandgames/WordBoggle.java class WordBoggle (line 10) | public final class WordBoggle { method WordBoggle (line 12) | private WordBoggle() { method boggleBoard (line 19) | public static List boggleBoard(char[][] board, String[] words) { method explore (line 34) | public static void explore(int i, int j, char[][] board, TrieNode trie... method getNeighbors (line 57) | public static List getNeighbors(int i, int j, char[][] boar... class TrieNode (line 96) | class TrieNode { class Trie (line 102) | class Trie { method Trie (line 107) | Trie() { method add (line 112) | public void add(String str) { FILE: src/main/java/com/thealgorithms/randomized/KargerMinCut.java class KargerMinCut (line 34) | public final class KargerMinCut { method KargerMinCut (line 46) | private KargerMinCut() { method findMinCut (line 49) | public static KargerOutput findMinCut(Collection nodeSet, Lis... method findMinCut (line 61) | public static KargerOutput findMinCut(Collection nodeSet, Lis... class DisjointSetUnion (line 77) | private static class DisjointSetUnion { method DisjointSetUnion (line 81) | DisjointSetUnion(int size) { method find (line 89) | int find(int i) { method union (line 101) | void union(int u, int v) { method inSameSet (line 116) | boolean inSameSet(int u, int v) { method getAnySet (line 124) | Set getAnySet() { class Graph (line 138) | private static class Graph { method Graph (line 142) | Graph(Collection nodeSet, List edges) { method copy (line 150) | Graph copy() { method findMinCut (line 154) | KargerOutput findMinCut() { method collectResult (line 181) | private KargerOutput collectResult(DisjointSetUnion dsu, int cutEdge... FILE: src/main/java/com/thealgorithms/randomized/MonteCarloIntegration.java class MonteCarloIntegration (line 27) | public final class MonteCarloIntegration { method MonteCarloIntegration (line 29) | private MonteCarloIntegration() { method approximate (line 44) | public static double approximate(Function fx, double a... method approximate (line 59) | public static double approximate(Function fx, double a... method doApproximate (line 63) | private static double doApproximate(Function fx, doubl... method validate (line 84) | private static boolean validate(Function fx, double a,... FILE: src/main/java/com/thealgorithms/randomized/RandomizedClosestPair.java class RandomizedClosestPair (line 22) | public final class RandomizedClosestPair { method RandomizedClosestPair (line 25) | private RandomizedClosestPair() { class Point (line 29) | public static class Point { method Point (line 33) | public Point(double x, double y) { method findClosestPairDistance (line 39) | public static double findClosestPairDistance(Point[] points) { method closestPair (line 52) | private static double closestPair(Point[] px, Point[] py) { method bruteForce (line 89) | private static double bruteForce(Point[] points) { method stripClosest (line 99) | private static double stripClosest(List strip, double d) { method distance (line 110) | private static double distance(Point p1, Point p2) { FILE: src/main/java/com/thealgorithms/randomized/RandomizedMatrixMultiplicationVerification.java class RandomizedMatrixMultiplicationVerification (line 5) | public final class RandomizedMatrixMultiplicationVerification { method RandomizedMatrixMultiplicationVerification (line 7) | private RandomizedMatrixMultiplicationVerification() { method verify (line 19) | public static boolean verify(int[][] a, int[][] b, int[][] c, int iter... FILE: src/main/java/com/thealgorithms/randomized/RandomizedQuickSort.java class RandomizedQuickSort (line 8) | public final class RandomizedQuickSort { method RandomizedQuickSort (line 10) | private RandomizedQuickSort() { method randomizedQuickSort (line 21) | public static void randomizedQuickSort(int[] arr, int low, int high) { method partition (line 37) | private static int partition(int[] arr, int low, int high) { method swap (line 59) | private static void swap(int[] arr, int i, int j) { FILE: src/main/java/com/thealgorithms/randomized/ReservoirSampling.java class ReservoirSampling (line 20) | public final class ReservoirSampling { method ReservoirSampling (line 23) | private ReservoirSampling() { method sample (line 34) | public static List sample(int[] stream, int sampleSize) { FILE: src/main/java/com/thealgorithms/recursion/DiceThrower.java class DiceThrower (line 21) | public final class DiceThrower { method DiceThrower (line 23) | private DiceThrower() { method getDiceCombinations (line 33) | public static List getDiceCombinations(int target) { method printDiceCombinations (line 45) | public static void printDiceCombinations(int target) { method generateCombinations (line 59) | private static List generateCombinations(String current, int r... method printCombinations (line 83) | private static void printCombinations(String current, int remaining) { method main (line 101) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/recursion/FactorialRecursion.java class FactorialRecursion (line 3) | public final class FactorialRecursion { method FactorialRecursion (line 4) | private FactorialRecursion() { method factorial (line 12) | public static long factorial(int n) { FILE: src/main/java/com/thealgorithms/recursion/FibonacciSeries.java class FibonacciSeries (line 12) | public final class FibonacciSeries { method FibonacciSeries (line 13) | private FibonacciSeries() { method fibonacci (line 24) | public static int fibonacci(int n) { FILE: src/main/java/com/thealgorithms/recursion/GenerateSubsets.java class GenerateSubsets (line 11) | public final class GenerateSubsets { method GenerateSubsets (line 13) | private GenerateSubsets() { method subsetRecursion (line 22) | public static List subsetRecursion(String str) { method generateSubsets (line 33) | private static List generateSubsets(String current, String rem... FILE: src/main/java/com/thealgorithms/recursion/SylvesterSequence.java class SylvesterSequence (line 19) | public final class SylvesterSequence { method SylvesterSequence (line 22) | private SylvesterSequence() { method sylvester (line 38) | public static BigInteger sylvester(int n) { FILE: src/main/java/com/thealgorithms/scheduling/AgingScheduling.java class AgingScheduling (line 16) | public final class AgingScheduling { class Task (line 18) | static class Task { method Task (line 23) | Task(String name, int priority) { method AgingScheduling (line 32) | public AgingScheduling() { method addTask (line 42) | public void addTask(String name, int priority) { method scheduleNext (line 52) | public String scheduleNext() { FILE: src/main/java/com/thealgorithms/scheduling/EDFScheduling.java class EDFScheduling (line 12) | public final class EDFScheduling { method EDFScheduling (line 13) | private EDFScheduling() { method EDFScheduling (line 23) | public EDFScheduling(final List processes) { method scheduleProcesses (line 34) | public List scheduleProcesses() { class Process (line 58) | public static class Process { method Process (line 65) | public Process(String processId, int burstTime, int deadline) { method getProcessId (line 71) | public String getProcessId() { method getBurstTime (line 75) | public int getBurstTime() { method getDeadline (line 79) | public int getDeadline() { method getWaitingTime (line 83) | public int getWaitingTime() { method setWaitingTime (line 87) | public void setWaitingTime(int waitingTime) { method getTurnAroundTime (line 91) | public int getTurnAroundTime() { method setTurnAroundTime (line 95) | public void setTurnAroundTime(int turnAroundTime) { FILE: src/main/java/com/thealgorithms/scheduling/FCFSScheduling.java class FCFSScheduling (line 10) | public class FCFSScheduling { method FCFSScheduling (line 14) | FCFSScheduling(final List processes) { method scheduleProcesses (line 18) | public void scheduleProcesses() { method evaluateWaitingTime (line 23) | private void evaluateWaitingTime() { method evaluateTurnAroundTime (line 42) | private void evaluateTurnAroundTime() { FILE: src/main/java/com/thealgorithms/scheduling/FairShareScheduling.java class FairShareScheduling (line 16) | public final class FairShareScheduling { class User (line 18) | static class User { method User (line 23) | User(String name) { method addWeight (line 29) | void addWeight(int weight) { method FairShareScheduling (line 36) | public FairShareScheduling() { method addUser (line 40) | public void addUser(String userName) { method addTask (line 44) | public void addTask(String userName, int weight) { method allocateResources (line 51) | public void allocateResources(int totalResources) { method getAllocatedResources (line 58) | public Map getAllocatedResources() { FILE: src/main/java/com/thealgorithms/scheduling/GangScheduling.java class GangScheduling (line 17) | public final class GangScheduling { class Gang (line 19) | static class Gang { method Gang (line 23) | Gang(String name) { method addTask (line 28) | void addTask(String task) { method getTasks (line 32) | List getTasks() { method GangScheduling (line 39) | public GangScheduling() { method addGang (line 43) | public void addGang(String gangName) { method addTaskToGang (line 47) | public void addTaskToGang(String gangName, String task) { method getGangSchedules (line 54) | public Map> getGangSchedules() { FILE: src/main/java/com/thealgorithms/scheduling/HighestResponseRatioNextScheduling.java class HighestResponseRatioNextScheduling (line 21) | public final class HighestResponseRatioNextScheduling { method HighestResponseRatioNextScheduling (line 26) | private HighestResponseRatioNextScheduling() { class Process (line 32) | private static class Process { method Process (line 39) | Process(String name, int arrivalTime, int burstTime) { method calculateResponseRatio (line 53) | double calculateResponseRatio(int currentTime) { method calculateTurnAroundTime (line 71) | public static int[] calculateTurnAroundTime(final String[] processName... method calculateWaitingTime (line 112) | public static int[] calculateWaitingTime(int[] turnAroundTime, int[] b... method findNextProcess (line 127) | private static int findNextProcess(Process[] processes, int currentTim... method findHighestResponseRatio (line 142) | private static int findHighestResponseRatio(Process[] processes, int c... FILE: src/main/java/com/thealgorithms/scheduling/JobSchedulingWithDeadline.java class JobSchedulingWithDeadline (line 15) | public final class JobSchedulingWithDeadline { method JobSchedulingWithDeadline (line 16) | private JobSchedulingWithDeadline() { class Job (line 25) | static class Job { method Job (line 39) | Job(int jobId, int arrivalTime, int deadline, int profit) { method jobSequencingWithDeadlines (line 61) | public static int[] jobSequencingWithDeadlines(Job[] jobs) { FILE: src/main/java/com/thealgorithms/scheduling/LotteryScheduling.java class LotteryScheduling (line 13) | public final class LotteryScheduling { method LotteryScheduling (line 14) | private LotteryScheduling() { method LotteryScheduling (line 25) | public LotteryScheduling(final List processes) { method LotteryScheduling (line 36) | public LotteryScheduling(final List processes, Random random) { method scheduleProcesses (line 47) | public List scheduleProcesses() { method selectProcessByTicket (line 84) | private Process selectProcessByTicket(int winningTicket) { class Process (line 100) | public static class Process { method Process (line 107) | public Process(String processId, int burstTime, int tickets) { method getProcessId (line 113) | public String getProcessId() { method getBurstTime (line 117) | public int getBurstTime() { method getTickets (line 121) | public int getTickets() { method getWaitingTime (line 125) | public int getWaitingTime() { method setWaitingTime (line 129) | public void setWaitingTime(int waitingTime) { method getTurnAroundTime (line 133) | public int getTurnAroundTime() { method setTurnAroundTime (line 137) | public void setTurnAroundTime(int turnAroundTime) { FILE: src/main/java/com/thealgorithms/scheduling/MLFQScheduler.java class MLFQScheduler (line 13) | public class MLFQScheduler { method MLFQScheduler (line 25) | public MLFQScheduler(int levels, int[] timeQuantums) { method addProcess (line 39) | public void addProcess(Process p) { method run (line 48) | public void run() { method allQueuesEmpty (line 82) | private boolean allQueuesEmpty() { method getCurrentTime (line 97) | public int getCurrentTime() { class Process (line 106) | class Process { method Process (line 120) | Process(int pid, int burstTime, int arrivalTime) { method execute (line 133) | public void execute(int timeSlice) { method isFinished (line 145) | public boolean isFinished() { FILE: src/main/java/com/thealgorithms/scheduling/MultiAgentScheduling.java class MultiAgentScheduling (line 17) | public class MultiAgentScheduling { class Agent (line 19) | static class Agent { method Agent (line 23) | Agent(String name) { method addTask (line 28) | void addTask(String task) { method getTasks (line 32) | List getTasks() { method MultiAgentScheduling (line 39) | public MultiAgentScheduling() { method addAgent (line 43) | public void addAgent(String agentName) { method assignTask (line 53) | public void assignTask(String agentName, String task) { method getScheduledTasks (line 65) | public Map> getScheduledTasks() { FILE: src/main/java/com/thealgorithms/scheduling/NonPreemptivePriorityScheduling.java class NonPreemptivePriorityScheduling (line 14) | public final class NonPreemptivePriorityScheduling { method NonPreemptivePriorityScheduling (line 16) | private NonPreemptivePriorityScheduling() { class Process (line 22) | static class Process implements Comparable { method Process (line 37) | Process(int id, int arrivalTime, int burstTime, int priority) { method compareTo (line 54) | @Override method scheduleProcesses (line 69) | public static Process[] scheduleProcesses(Process[] processes) { method calculateAverageWaitingTime (line 105) | public static double calculateAverageWaitingTime(Process[] processes, ... method calculateAverageTurnaroundTime (line 123) | public static double calculateAverageTurnaroundTime(Process[] processe... FILE: src/main/java/com/thealgorithms/scheduling/PreemptivePriorityScheduling.java class PreemptivePriorityScheduling (line 15) | public class PreemptivePriorityScheduling { method PreemptivePriorityScheduling (line 19) | public PreemptivePriorityScheduling(Collection process... method scheduleProcesses (line 24) | public void scheduleProcesses() { method updateArrivedProcesses (line 51) | private void updateArrivedProcesses(int currentTime, List getAllocatedResources() { FILE: src/main/java/com/thealgorithms/scheduling/RRScheduling.java class RRScheduling (line 16) | public class RRScheduling { method RRScheduling (line 20) | RRScheduling(final List processes, int quantumTime) { method scheduleProcesses (line 25) | public void scheduleProcesses() { method evaluateTurnAroundTime (line 30) | private void evaluateTurnAroundTime() { method evaluateWaitingTime (line 96) | private void evaluateWaitingTime() { FILE: src/main/java/com/thealgorithms/scheduling/RandomScheduling.java class RandomScheduling (line 19) | public final class RandomScheduling { method RandomScheduling (line 30) | public RandomScheduling(Collection tasks, Random random) { method schedule (line 40) | public List schedule() { FILE: src/main/java/com/thealgorithms/scheduling/SJFScheduling.java class SJFScheduling (line 14) | public class SJFScheduling { method SJFScheduling (line 18) | public SJFScheduling(final List processes) { method sortProcessesByArrivalTime (line 24) | private static void sortProcessesByArrivalTime(List pr... method scheduleProcesses (line 31) | public void scheduleProcesses() { method findShortestJob (line 74) | private ProcessDetails findShortestJob(Collection read... method getSchedule (line 81) | public List getSchedule() { method getProcesses (line 85) | public List getProcesses() { FILE: src/main/java/com/thealgorithms/scheduling/SRTFScheduling.java class SRTFScheduling (line 19) | public class SRTFScheduling { method SRTFScheduling (line 27) | public SRTFScheduling(ArrayList processes) { method evaluateScheduling (line 33) | public void evaluateScheduling() { FILE: src/main/java/com/thealgorithms/scheduling/SelfAdjustingScheduling.java class SelfAdjustingScheduling (line 16) | public final class SelfAdjustingScheduling { class Task (line 18) | private static class Task implements Comparable { method Task (line 23) | Task(String name, int priority) { method incrementWaitTime (line 29) | void incrementWaitTime() { method compareTo (line 34) | @Override method SelfAdjustingScheduling (line 42) | public SelfAdjustingScheduling() { method addTask (line 46) | public void addTask(String name, int priority) { method scheduleNext (line 50) | public String scheduleNext() { method isEmpty (line 60) | public boolean isEmpty() { FILE: src/main/java/com/thealgorithms/scheduling/SlackTimeScheduling.java class SlackTimeScheduling (line 16) | public class SlackTimeScheduling { class Task (line 18) | static class Task { method Task (line 23) | Task(String name, int executionTime, int deadline) { method getSlackTime (line 29) | int getSlackTime() { method SlackTimeScheduling (line 36) | public SlackTimeScheduling() { method addTask (line 47) | public void addTask(String name, int executionTime, int deadline) { method scheduleTasks (line 56) | public List scheduleTasks() { FILE: src/main/java/com/thealgorithms/scheduling/diskscheduling/CircularLookScheduling.java class CircularLookScheduling (line 18) | public class CircularLookScheduling { method CircularLookScheduling (line 23) | public CircularLookScheduling(int startPosition, boolean movingUp, int... method execute (line 29) | public List execute(List requests) { method getCurrentPosition (line 73) | public int getCurrentPosition() { method isMovingUp (line 77) | public boolean isMovingUp() { FILE: src/main/java/com/thealgorithms/scheduling/diskscheduling/CircularScanScheduling.java class CircularScanScheduling (line 16) | public class CircularScanScheduling { method CircularScanScheduling (line 21) | public CircularScanScheduling(int startPosition, boolean movingUp, int... method execute (line 27) | public List execute(List requests) { method getCurrentPosition (line 76) | public int getCurrentPosition() { method isMovingUp (line 80) | public boolean isMovingUp() { FILE: src/main/java/com/thealgorithms/scheduling/diskscheduling/LookScheduling.java class LookScheduling (line 13) | public class LookScheduling { method LookScheduling (line 18) | public LookScheduling(int startPosition, boolean initialDirection, int... method execute (line 30) | public List execute(List requests) { method getCurrentPosition (line 84) | public int getCurrentPosition() { method isMovingUp (line 88) | public boolean isMovingUp() { method getFarthestPosition (line 92) | public int getFarthestPosition() { FILE: src/main/java/com/thealgorithms/scheduling/diskscheduling/SSFScheduling.java class SSFScheduling (line 21) | public class SSFScheduling { method SSFScheduling (line 24) | public SSFScheduling(int currentPosition) { method execute (line 28) | public List execute(Collection requests) { method findClosest (line 41) | private int findClosest(List requests) { method getCurrentPosition (line 54) | public int getCurrentPosition() { FILE: src/main/java/com/thealgorithms/scheduling/diskscheduling/ScanScheduling.java class ScanScheduling (line 21) | public class ScanScheduling { method ScanScheduling (line 26) | public ScanScheduling(int headPosition, boolean movingUp, int diskSize) { method execute (line 32) | public List execute(List requests) { method getHeadPosition (line 75) | public int getHeadPosition() { method isMovingUp (line 79) | public boolean isMovingUp() { FILE: src/main/java/com/thealgorithms/searches/BM25InvertedIndex.java class Movie (line 16) | class Movie { method Movie (line 31) | Movie(int docId, String name, double imdbRating, int releaseYear, Stri... method getWords (line 44) | public String[] getWords() { method toString (line 48) | @Override class SearchResult (line 55) | class SearchResult { method SearchResult (line 64) | SearchResult(int docId, double relevanceScore) { method getDocId (line 69) | public int getDocId() { method toString (line 73) | @Override method equals (line 79) | @Override method hashCode (line 91) | @Override method getRelevanceScore (line 96) | public double getRelevanceScore() { class BM25InvertedIndex (line 101) | public final class BM25InvertedIndex { method BM25InvertedIndex (line 113) | BM25InvertedIndex() { method addMovie (line 128) | public void addMovie(int docId, String name, double imdbRating, int re... method getMoviesLength (line 156) | public int getMoviesLength() { method search (line 165) | public List search(String term) { method computeBM25Score (line 204) | private double computeBM25Score(int termFrequency, double docLength, d... method computeIDF (line 216) | private double computeIDF(int docFrequency) { FILE: src/main/java/com/thealgorithms/searches/BinarySearch.java class BinarySearch (line 38) | class BinarySearch implements SearchAlgorithm { method find (line 59) | @Override method search (line 92) | private > int search(T[] array, T key, int lef... FILE: src/main/java/com/thealgorithms/searches/BinarySearch2dArray.java class BinarySearch2dArray (line 17) | public final class BinarySearch2dArray { method BinarySearch2dArray (line 19) | private BinarySearch2dArray() { method binarySearch (line 31) | static int[] binarySearch(int[][] arr, int target) { method binarySearch (line 106) | static int[] binarySearch(int[][] arr, int target, int row, int colSta... FILE: src/main/java/com/thealgorithms/searches/BoyerMoore.java class BoyerMoore (line 8) | public class BoyerMoore { method BoyerMoore (line 14) | public BoyerMoore(String pat) { method search (line 28) | public int search(String text) { method staticSearch (line 55) | public static int staticSearch(String text, String pattern) { FILE: src/main/java/com/thealgorithms/searches/BreadthFirstSearch.java class BreadthFirstSearch (line 18) | public class BreadthFirstSearch { method search (line 29) | public Optional> search(final Node root, final T value) { method getVisited (line 68) | public List getVisited() { FILE: src/main/java/com/thealgorithms/searches/DepthFirstSearch.java class DepthFirstSearch (line 13) | public class DepthFirstSearch { method recursiveSearch (line 17) | public Optional> recursiveSearch(final Node node, final Int... method getVisited (line 29) | public List getVisited() { FILE: src/main/java/com/thealgorithms/searches/ExponentialSearch.java class ExponentialSearch (line 22) | class ExponentialSearch implements SearchAlgorithm { method find (line 32) | @Override FILE: src/main/java/com/thealgorithms/searches/FibonacciSearch.java class FibonacciSearch (line 18) | @SuppressWarnings({"rawtypes", "unchecked"}) method find (line 30) | @Override method isSorted (line 79) | private boolean isSorted(Comparable[] array) { FILE: src/main/java/com/thealgorithms/searches/HowManyTimesRotated.java class HowManyTimesRotated (line 28) | final class HowManyTimesRotated { method HowManyTimesRotated (line 29) | private HowManyTimesRotated() { method main (line 32) | public static void main(String[] args) { method rotated (line 44) | public static int rotated(int[] a) { FILE: src/main/java/com/thealgorithms/searches/InterpolationSearch.java class InterpolationSearch (line 21) | class InterpolationSearch { method find (line 30) | public int find(int[] array, int key) { FILE: src/main/java/com/thealgorithms/searches/IterativeBinarySearch.java class IterativeBinarySearch (line 21) | public final class IterativeBinarySearch implements SearchAlgorithm { method find (line 30) | @Override FILE: src/main/java/com/thealgorithms/searches/IterativeTernarySearch.java class IterativeTernarySearch (line 28) | public class IterativeTernarySearch implements SearchAlgorithm { method find (line 30) | @Override FILE: src/main/java/com/thealgorithms/searches/JumpSearch.java class JumpSearch (line 28) | public class JumpSearch implements SearchAlgorithm { method find (line 37) | @Override FILE: src/main/java/com/thealgorithms/searches/KMPSearch.java class KMPSearch (line 3) | class KMPSearch { method kmpSearch (line 5) | int kmpSearch(String pat, String txt) { method computeLPSArray (line 46) | void computeLPSArray(String pat, int m, int[] lps) { FILE: src/main/java/com/thealgorithms/searches/LinearSearch.java class LinearSearch (line 24) | public class LinearSearch implements SearchAlgorithm { method find (line 33) | @Override FILE: src/main/java/com/thealgorithms/searches/LinearSearchThread.java class LinearSearchThread (line 21) | public final class LinearSearchThread { method LinearSearchThread (line 22) | private LinearSearchThread() { class Searcher (line 30) | class Searcher extends Thread { method Searcher (line 45) | Searcher(int[] arr, int left, int right, int x) { method run (line 55) | @Override method getResult (line 71) | boolean getResult() { FILE: src/main/java/com/thealgorithms/searches/LowerBound.java class LowerBound (line 23) | class LowerBound implements SearchAlgorithm { method find (line 31) | @Override method search (line 45) | private > int search(T[] array, T key, int lef... FILE: src/main/java/com/thealgorithms/searches/MonteCarloTreeSearch.java class MonteCarloTreeSearch (line 15) | public class MonteCarloTreeSearch { class Node (line 17) | public class Node { method Node (line 26) | public Node() { method Node (line 29) | public Node(Node parent, boolean isPlayersTurn) { method monteCarloTreeSearch (line 49) | public Node monteCarloTreeSearch(Node rootNode) { method addChildNodes (line 80) | public void addChildNodes(Node node, int childCount) { method getPromisingNode (line 94) | public Node getPromisingNode(Node rootNode) { method simulateRandomPlay (line 135) | public void simulateRandomPlay(Node promisingNode) { method getWinnerNode (line 162) | public Node getWinnerNode(Node rootNode) { method printScores (line 166) | public void printScores(Node rootNode) { FILE: src/main/java/com/thealgorithms/searches/OrderAgnosticBinarySearch.java class OrderAgnosticBinarySearch (line 14) | public final class OrderAgnosticBinarySearch { method OrderAgnosticBinarySearch (line 15) | private OrderAgnosticBinarySearch() { method binSearchAlgo (line 18) | static int binSearchAlgo(int[] arr, int start, int end, int target) { FILE: src/main/java/com/thealgorithms/searches/QuickSelect.java class QuickSelect (line 12) | public final class QuickSelect { method QuickSelect (line 13) | private QuickSelect() { method select (line 31) | public static > T select(List list, int n) { method selectIndex (line 53) | private static > int selectIndex(List list,... method selectIndex (line 57) | private static > int selectIndex(List list,... method partition (line 74) | private static > int partition(List list, i... method pivot (line 100) | private static > int pivot(List list, int l... method partition5 (line 120) | private static > int partition5(List list, ... FILE: src/main/java/com/thealgorithms/searches/RabinKarpAlgorithm.java class RabinKarpAlgorithm (line 5) | public final class RabinKarpAlgorithm { method RabinKarpAlgorithm (line 6) | private RabinKarpAlgorithm() { method search (line 11) | public static int search(String pattern, String text, int primeNumber) { FILE: src/main/java/com/thealgorithms/searches/RandomSearch.java class RandomSearch (line 19) | public class RandomSearch implements SearchAlgorithm { method find (line 30) | @Override FILE: src/main/java/com/thealgorithms/searches/RecursiveBinarySearch.java class SearchAlgorithm (line 10) | abstract class SearchAlgorithm> { method find (line 12) | public abstract int find(T[] arr, T target); class RecursiveBinarySearch (line 15) | public class RecursiveBinarySearch> extends Sear... method find (line 18) | @Override method binsear (line 25) | public int binsear(T[] arr, int left, int right, T target) { method main (line 49) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/searches/RotatedBinarySearch.java class RotatedBinarySearch (line 20) | public final class RotatedBinarySearch implements SearchAlgorithm { method find (line 22) | @Override FILE: src/main/java/com/thealgorithms/searches/RowColumnWiseSorted2dArrayBinarySearch.java class RowColumnWiseSorted2dArrayBinarySearch (line 23) | public class RowColumnWiseSorted2dArrayBinarySearch implements MatrixSea... method find (line 25) | @Override method search (line 30) | public static > int[] search(T[][] matrix, T t... FILE: src/main/java/com/thealgorithms/searches/SaddlebackSearch.java class SaddlebackSearch (line 17) | public final class SaddlebackSearch { method SaddlebackSearch (line 18) | private SaddlebackSearch() { method find (line 32) | static int[] find(int[][] arr, int row, int col, int key) { FILE: src/main/java/com/thealgorithms/searches/SearchInARowAndColWiseSortedMatrix.java class SearchInARowAndColWiseSortedMatrix (line 3) | public class SearchInARowAndColWiseSortedMatrix { method search (line 11) | public int[] search(int[][] matrix, int value) { FILE: src/main/java/com/thealgorithms/searches/SentinelLinearSearch.java class SentinelLinearSearch (line 36) | public class SentinelLinearSearch implements SearchAlgorithm { method find (line 46) | @Override method findNull (line 91) | private > int findNull(T[] array) { FILE: src/main/java/com/thealgorithms/searches/SquareRootBinarySearch.java class SquareRootBinarySearch (line 15) | public final class SquareRootBinarySearch { method SquareRootBinarySearch (line 16) | private SquareRootBinarySearch() { method squareRoot (line 27) | static long squareRoot(long num) { FILE: src/main/java/com/thealgorithms/searches/TernarySearch.java class TernarySearch (line 20) | public class TernarySearch implements SearchAlgorithm { method find (line 27) | @Override method ternarySearch (line 39) | private > int ternarySearch(T[] arr, T key, in... FILE: src/main/java/com/thealgorithms/searches/UnionFind.java class UnionFind (line 18) | public class UnionFind { method UnionFind (line 29) | public UnionFind(int n) { method find (line 45) | public int find(int i) { method union (line 65) | public void union(int x, int y) { method count (line 89) | public int count() { method toString (line 100) | @Override FILE: src/main/java/com/thealgorithms/searches/UpperBound.java class UpperBound (line 23) | class UpperBound implements SearchAlgorithm { method find (line 31) | @Override method search (line 45) | private > int search(T[] array, T key, int lef... FILE: src/main/java/com/thealgorithms/slidingwindow/CountNiceSubarrays.java class CountNiceSubarrays (line 15) | public final class CountNiceSubarrays { method CountNiceSubarrays (line 18) | private CountNiceSubarrays() { method countNiceSubarrays (line 28) | public static int countNiceSubarrays(int[] nums, int k) { FILE: src/main/java/com/thealgorithms/slidingwindow/LongestSubarrayWithSumLessOrEqualToK.java class LongestSubarrayWithSumLessOrEqualToK (line 15) | public final class LongestSubarrayWithSumLessOrEqualToK { method LongestSubarrayWithSumLessOrEqualToK (line 18) | private LongestSubarrayWithSumLessOrEqualToK() { method longestSubarrayWithSumLEK (line 28) | public static int longestSubarrayWithSumLEK(int[] arr, int k) { FILE: src/main/java/com/thealgorithms/slidingwindow/LongestSubstringWithoutRepeatingCharacters.java class LongestSubstringWithoutRepeatingCharacters (line 17) | public final class LongestSubstringWithoutRepeatingCharacters { method LongestSubstringWithoutRepeatingCharacters (line 20) | private LongestSubstringWithoutRepeatingCharacters() { method lengthOfLongestSubstring (line 29) | public static int lengthOfLongestSubstring(String s) { FILE: src/main/java/com/thealgorithms/slidingwindow/MaxSumKSizeSubarray.java class MaxSumKSizeSubarray (line 15) | public final class MaxSumKSizeSubarray { method MaxSumKSizeSubarray (line 18) | private MaxSumKSizeSubarray() { method maxSumKSizeSubarray (line 28) | public static int maxSumKSizeSubarray(int[] arr, int k) { FILE: src/main/java/com/thealgorithms/slidingwindow/MaximumSlidingWindow.java class MaximumSlidingWindow (line 17) | public class MaximumSlidingWindow { method maxSlidingWindow (line 26) | public int[] maxSlidingWindow(int[] nums, int windowSize) { FILE: src/main/java/com/thealgorithms/slidingwindow/MinSumKSizeSubarray.java class MinSumKSizeSubarray (line 17) | public final class MinSumKSizeSubarray { method MinSumKSizeSubarray (line 20) | private MinSumKSizeSubarray() { method minSumKSizeSubarray (line 30) | public static int minSumKSizeSubarray(int[] arr, int k) { FILE: src/main/java/com/thealgorithms/slidingwindow/MinimumWindowSubstring.java class MinimumWindowSubstring (line 15) | public final class MinimumWindowSubstring { method MinimumWindowSubstring (line 17) | private MinimumWindowSubstring() { method minWindow (line 27) | public static String minWindow(String s, String t) { FILE: src/main/java/com/thealgorithms/slidingwindow/ShortestCoprimeSegment.java class ShortestCoprimeSegment (line 27) | public final class ShortestCoprimeSegment { method ShortestCoprimeSegment (line 29) | private ShortestCoprimeSegment() { method shortestCoprimeSegment (line 36) | public static long[] shortestCoprimeSegment(long[] arr) { method legalSegment (line 66) | private static boolean legalSegment(DoubleStack front, DoubleStack bac... method gcd (line 70) | private static long gcd(long a, long b) { method remove (line 89) | private static void remove(DoubleStack front, DoubleStack back) { class DoubleStack (line 101) | private static class DoubleStack { method DoubleStack (line 105) | DoubleStack() { method f (line 111) | long f(long a, long b) { // Can be replaced with other function method push (line 115) | public void push(long x) { method top (line 120) | public long top() { method pop (line 124) | public long pop() { method isEmpty (line 131) | public boolean isEmpty() { FILE: src/main/java/com/thealgorithms/sorts/AdaptiveMergeSort.java class AdaptiveMergeSort (line 3) | public class AdaptiveMergeSort implements SortAlgorithm { method sort (line 4) | @SuppressWarnings("unchecked") method sort (line 14) | private > void sort(T[] array, T[] aux, int lo... method merge (line 24) | private > void merge(T[] array, T[] aux, int l... FILE: src/main/java/com/thealgorithms/sorts/BeadSort.java class BeadSort (line 5) | public class BeadSort { type BeadState (line 6) | private enum BeadState { BEAD, EMPTY } method sort (line 15) | public int[] sort(int[] array) { method allInputsMustBeNonNegative (line 20) | private void allInputsMustBeNonNegative(final int[] array) { method fillGrid (line 26) | private BeadState[][] fillGrid(final int[] array) { method getEmptyGrid (line 41) | private BeadState[][] getEmptyGrid(final int arrayLength, final int ma... method extractSortedFromGrid (line 52) | private int[] extractSortedFromGrid(final BeadState[][] grid) { FILE: src/main/java/com/thealgorithms/sorts/BinaryInsertionSort.java class BinaryInsertionSort (line 8) | public class BinaryInsertionSort implements SortAlgorithm { method sort (line 17) | public > T[] sort(T[] array) { FILE: src/main/java/com/thealgorithms/sorts/BitonicSort.java class BitonicSort (line 9) | public class BitonicSort implements SortAlgorithm { type Direction (line 10) | private enum Direction { method sort (line 22) | @Override method bitonicSort (line 39) | private > void bitonicSort(final T[] array, fi... method bitonicMerge (line 63) | private > void bitonicMerge(T[] array, int low... method nextPowerOfTwo (line 85) | private static int nextPowerOfTwo(int n) { method max (line 109) | private static > T max(final T[] array) { FILE: src/main/java/com/thealgorithms/sorts/BogoSort.java class BogoSort (line 9) | public class BogoSort implements SortAlgorithm { method isSorted (line 13) | private static > boolean isSorted(T[] array) { method nextPermutation (line 23) | private static void nextPermutation(T[] array) { method sort (line 32) | public > T[] sort(T[] array) { method main (line 40) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/sorts/BubbleSort.java class BubbleSort (line 8) | class BubbleSort implements SortAlgorithm { method sort (line 24) | @Override FILE: src/main/java/com/thealgorithms/sorts/BubbleSortRecursive.java class BubbleSortRecursive (line 6) | public class BubbleSortRecursive implements SortAlgorithm { method sort (line 11) | @Override method bubbleSort (line 23) | private static > void bubbleSort(T[] array, in... FILE: src/main/java/com/thealgorithms/sorts/BucketSort.java class BucketSort (line 11) | public class BucketSort implements SortAlgorithm { method sort (line 16) | @Override method calculateNumberOfBuckets (line 38) | private int calculateNumberOfBuckets(final int arrayLength) { method initializeBuckets (line 49) | private > List> initializeBuckets(int ... method distributeElementsIntoBuckets (line 67) | private > void distributeElementsIntoBuckets(T... method concatenateBuckets (line 82) | private > T[] concatenateBuckets(Iterable> int hash(final T element, final T mi... method findMin (line 111) | private > T findMin(T[] array) { method findMax (line 121) | private > T findMax(T[] array) { FILE: src/main/java/com/thealgorithms/sorts/CircleSort.java class CircleSort (line 3) | public class CircleSort implements SortAlgorithm { method sort (line 8) | @Override method doSort (line 28) | private > boolean doSort(final T[] array, fina... FILE: src/main/java/com/thealgorithms/sorts/CocktailShakerSort.java class CocktailShakerSort (line 12) | class CocktailShakerSort implements SortAlgorithm { method sort (line 21) | @Override method performForwardPass (line 47) | private > int performForwardPass(final T[] arr... method performBackwardPass (line 69) | private > int performBackwardPass(final T[] ar... FILE: src/main/java/com/thealgorithms/sorts/CombSort.java class CombSort (line 18) | class CombSort implements SortAlgorithm { method getNextGap (line 27) | private int getNextGap(int gap) { method sort (line 39) | @Override method performSwaps (line 60) | private > boolean performSwaps(final T[] arr, ... FILE: src/main/java/com/thealgorithms/sorts/CountingSort.java class CountingSort (line 17) | public final class CountingSort { method CountingSort (line 18) | private CountingSort() { method sort (line 27) | public static int[] sort(int[] array) { method computeHistogram (line 38) | private static int[] computeHistogram(final int[] array, final int shi... method toCumulative (line 46) | private static void toCumulative(int[] count) { method reconstructSorted (line 52) | private static int[] reconstructSorted(final int[] cumulativeCount, fi... FILE: src/main/java/com/thealgorithms/sorts/CycleSort.java class CycleSort (line 8) | class CycleSort implements SortAlgorithm { method sort (line 16) | @Override method findPosition (line 48) | private > int findPosition(final T[] array, fi... method placeItem (line 67) | private > T placeItem(final T[] array, final T... method replace (line 83) | private > T replace(final T[] array, final int... FILE: src/main/java/com/thealgorithms/sorts/DarkSort.java class DarkSort (line 9) | class DarkSort { method sort (line 17) | public Integer[] sort(Integer[] unsorted) { method findMax (line 50) | private int findMax(Integer[] arr) { FILE: src/main/java/com/thealgorithms/sorts/DualPivotQuickSort.java class DualPivotQuickSort (line 9) | public class DualPivotQuickSort implements SortAlgorithm { method sort (line 18) | @Override method dualPivotQuicksort (line 36) | private static > void dualPivotQuicksort(final... method partition (line 55) | private static > int[] partition(final T[] arr... FILE: src/main/java/com/thealgorithms/sorts/DutchNationalFlagSort.java class DutchNationalFlagSort (line 12) | public class DutchNationalFlagSort implements SortAlgorithm { method sort (line 14) | @Override method sort (line 19) | public > T[] sort(T[] array, T intendedMiddle) { method dutchNationalFlagSort (line 23) | private > T[] dutchNationalFlagSort(final T[] ... FILE: src/main/java/com/thealgorithms/sorts/ExchangeSort.java class ExchangeSort (line 22) | class ExchangeSort implements SortAlgorithm { method sort (line 30) | @Override FILE: src/main/java/com/thealgorithms/sorts/FlashSort.java class FlashSort (line 24) | public class FlashSort implements SortAlgorithm { method FlashSort (line 27) | public FlashSort() { method FlashSort (line 30) | public FlashSort(double classificationRatio) { method getClassificationRatio (line 37) | public double getClassificationRatio() { method setClassificationRatio (line 41) | public void setClassificationRatio(double classificationRatio) { method sort (line 55) | @Override method flashSort (line 67) | private > void flashSort(T[] arr) { method findMin (line 101) | private > T findMin(final T[] arr) { method findMaxIndex (line 118) | private > int findMaxIndex(final T[] a... method classify (line 137) | private > void classify(final T[] arr,... method transform (line 149) | private void transform(final int[] classificationArray) { method permute (line 166) | private > void permute(final T[] arr, ... method insertionSort (line 194) | private > void insertionSort(final T[]... FILE: src/main/java/com/thealgorithms/sorts/GnomeSort.java class GnomeSort (line 9) | public class GnomeSort implements SortAlgorithm { method sort (line 11) | @Override FILE: src/main/java/com/thealgorithms/sorts/HeapSort.java class HeapSort (line 19) | public class HeapSort implements SortAlgorithm { method sort (line 27) | @Override method heapify (line 39) | private > void heapify(final T[] array, final ... method siftDown (line 45) | private > void siftDown(final T[] array, int k... FILE: src/main/java/com/thealgorithms/sorts/InsertionSort.java class InsertionSort (line 21) | class InsertionSort implements SortAlgorithm { method sort (line 30) | @Override method sort (line 44) | public > T[] sort(T[] items, final int startIn... method sentinelSort (line 72) | public > T[] sentinelSort(T[] array) { method findMinIndex (line 100) | private > int findMinIndex(final T[] array) { FILE: src/main/java/com/thealgorithms/sorts/IntrospectiveSort.java class IntrospectiveSort (line 8) | public class IntrospectiveSort implements SortAlgorithm { method sort (line 19) | @Override method introspectiveSort (line 38) | private static > void introspectiveSort(T[] ar... method partition (line 60) | private static > int partition(T[] array, fina... method insertionSort (line 83) | private static > void insertionSort(T[] array,... method heapSort (line 103) | private static > void heapSort(T[] array, fina... method heapify (line 123) | private static > void heapify(T[] array, final... FILE: src/main/java/com/thealgorithms/sorts/LinkListSort.java class LinkListSort (line 8) | public class LinkListSort { method isSorted (line 10) | public static boolean isSorted(int[] p, int option) { method compare (line 126) | boolean compare(int[] a, int[] b) { class Node (line 138) | class Node { class Task (line 145) | class Task { method sortByMergeSort (line 149) | public Node sortByMergeSort(Node head) { method count (line 171) | int count(Node head) { method task (line 182) | void task(int[] n, int i, int j) { method task1 (line 192) | void task1(int[] n, int s, int m, int e) { class Task1 (line 218) | class Task1 { method sortByInsertionSort (line 220) | public Node sortByInsertionSort(Node head) { method count (line 247) | static int count(Node head) { class Task2 (line 260) | class Task2 { method sortByHeapSort (line 262) | public Node sortByHeapSort(Node head) { method count (line 283) | int count(Node head) { method task (line 294) | void task(int[] n) { method task1 (line 308) | void task1(int[] n, int k, int i) { FILE: src/main/java/com/thealgorithms/sorts/MergeSort.java class MergeSort (line 10) | @SuppressWarnings("rawtypes") method sort (line 27) | @Override method doSort (line 39) | private > void doSort(T[] arr, int left, int r... method merge (line 57) | @SuppressWarnings("unchecked") FILE: src/main/java/com/thealgorithms/sorts/MergeSortNoExtraSpace.java class MergeSortNoExtraSpace (line 9) | public final class MergeSortNoExtraSpace { method MergeSortNoExtraSpace (line 10) | private MergeSortNoExtraSpace() { method sort (line 20) | public static int[] sort(int[] array) { method mergeSort (line 41) | public static void mergeSort(int[] array, int start, int end, int maxE... method merge (line 59) | private static void merge(int[] array, int start, int middle, int end,... FILE: src/main/java/com/thealgorithms/sorts/MergeSortRecursive.java class MergeSortRecursive (line 6) | public class MergeSortRecursive { method MergeSortRecursive (line 10) | public MergeSortRecursive(List arr) { method mergeSort (line 14) | public List mergeSort() { method merge (line 18) | private static List merge(List arr) { method sort (line 36) | private static List sort(List unsortedA, List> boolean performOddSort(T[] array) { method performEvenSort (line 41) | private > boolean performEvenSort(T[] array) { FILE: src/main/java/com/thealgorithms/sorts/PancakeSort.java class PancakeSort (line 9) | public class PancakeSort implements SortAlgorithm { method sort (line 11) | @Override method findIndexOfMax (line 33) | private > int findIndexOfMax(T[] array, int cu... FILE: src/main/java/com/thealgorithms/sorts/PatienceSort.java class PatienceSort (line 12) | public class PatienceSort implements SortAlgorithm { method sort (line 21) | @Override method formPiles (line 43) | private static > List> formPiles(final... method mergePiles (line 75) | private static > PriorityQueue> me... method extractPiles (line 90) | private static > void extractPiles(final T[] a... method compareTo (line 107) | @Override FILE: src/main/java/com/thealgorithms/sorts/PigeonholeSort.java class PigeonholeSort (line 7) | public final class PigeonholeSort { method PigeonholeSort (line 8) | private PigeonholeSort() { method sort (line 18) | public static int[] sort(int[] array) { method checkForNegativeInput (line 41) | private static void checkForNegativeInput(int[] array) { method createPigeonHoles (line 55) | private static List> createPigeonHoles(int maxElement) { method populatePigeonHoles (line 69) | private static void populatePigeonHoles(int[] array, List> void doSort(T[] array, final ... method randomPartition (line 67) | private static > int randomPartition(T[] array... method partition (line 82) | private static > int partition(T[] array, int ... FILE: src/main/java/com/thealgorithms/sorts/RadixSort.java class RadixSort (line 10) | public final class RadixSort { method RadixSort (line 13) | private RadixSort() { method sort (line 23) | public static int[] sort(int[] array) { method checkForNegativeInput (line 39) | private static void checkForNegativeInput(int[] array) { method radixSort (line 47) | private static void radixSort(int[] array) { method countingSortByDigit (line 60) | private static void countingSortByDigit(int[] array, int exp) { method countDigits (line 67) | private static int[] countDigits(int[] array, int exp) { method getDigit (line 75) | private static int getDigit(int number, int position) { method accumulateCounts (line 79) | private static void accumulateCounts(int[] count) { method buildOutput (line 85) | private static int[] buildOutput(int[] array, int exp, int[] count) { method copyOutput (line 95) | private static void copyOutput(int[] array, int[] output) { FILE: src/main/java/com/thealgorithms/sorts/SelectionSort.java class SelectionSort (line 3) | public class SelectionSort implements SortAlgorithm { method sort (line 16) | @Override method findIndexOfMin (line 26) | private static > int findIndexOfMin(T[] array,... FILE: src/main/java/com/thealgorithms/sorts/SelectionSortRecursive.java class SelectionSortRecursive (line 6) | public class SelectionSortRecursive implements SortAlgorithm { method sort (line 15) | public > T[] sort(T[] array) { method recursiveSelectionSort (line 30) | private static > void recursiveSelectionSort(T... method findMinIndex (line 49) | private static > int findMinIndex(T[] array, f... FILE: src/main/java/com/thealgorithms/sorts/ShellSort.java class ShellSort (line 3) | public class ShellSort implements SortAlgorithm { method sort (line 12) | @Override method calculateInitialGap (line 34) | private int calculateInitialGap(final int length) { method calculateNextGap (line 48) | private int calculateNextGap(final int currentGap) { method performGapInsertionSort (line 59) | private > void performGapInsertionSort(final T... FILE: src/main/java/com/thealgorithms/sorts/SlowSort.java class SlowSort (line 7) | public class SlowSort implements SortAlgorithm { method sort (line 9) | @Override method sort (line 15) | private > void sort(T[] array, int i, int j) { FILE: src/main/java/com/thealgorithms/sorts/SmoothSort.java class SmoothSort (line 24) | public class SmoothSort implements SortAlgorithm { method sort (line 40) | @Override method sift (line 109) | private static > void sift(final T[] array, in... method trinkle (line 134) | private static > void trinkle(final T[] array,... FILE: src/main/java/com/thealgorithms/sorts/SortAlgorithm.java type SortAlgorithm (line 11) | @SuppressWarnings("rawtypes") method sort (line 19) | > T[] sort(T[] unsorted); method sort (line 27) | @SuppressWarnings("unchecked") FILE: src/main/java/com/thealgorithms/sorts/SortUtils.java class SortUtils (line 7) | final class SortUtils { method SortUtils (line 8) | private SortUtils() { method swap (line 19) | public static void swap(T[] array, int i, int j) { method less (line 34) | public static > boolean less(T firstElement, T... method greater (line 45) | public static > boolean greater(T firstElement... method greaterOrEqual (line 56) | static > boolean greaterOrEqual(T firstElement... method print (line 65) | static void print(List listToPrint) { method print (line 75) | static void print(T[] array) { method flip (line 86) | public static > void flip(T[] array, int left,... method isSorted (line 98) | public static > boolean isSorted(T[] array) { method isSorted (line 113) | public static > boolean isSorted(List list) { FILE: src/main/java/com/thealgorithms/sorts/SortUtilsRandomGenerator.java class SortUtilsRandomGenerator (line 5) | public final class SortUtilsRandomGenerator { method SortUtilsRandomGenerator (line 6) | private SortUtilsRandomGenerator() { method generateArray (line 23) | public static Double[] generateArray(int size) { method generateDouble (line 36) | public static Double generateDouble() { method generateInt (line 45) | public static int generateInt(int n) { FILE: src/main/java/com/thealgorithms/sorts/SpreadSort.java class SpreadSort (line 9) | @SuppressWarnings("rawtypes") method SpreadSort (line 26) | public SpreadSort(int insertionSortThreshold, int initialBucketCapacit... method SpreadSort (line 45) | public SpreadSort() { method sort (line 56) | @Override method spreadSort (line 73) | private > void spreadSort(final T[] array, fin... method findMin (line 107) | private > T findMin(final T[] array, final int... method findMax (line 126) | private > T findMax(final T[] array, final int... method calculateNumBuckets (line 142) | private int calculateNumBuckets(final int segmentSize) { method createBuckets (line 154) | @SuppressWarnings("unchecked") method distributeElements (line 175) | private > void distributeElements(final T[] ar... method collectElements (line 192) | private > void collectElements(final T[] array... method insertionSort (line 213) | private > void insertionSort(final T[] array, ... class Bucket (line 230) | private static class Bucket> { method Bucket (line 237) | @SuppressWarnings("unchecked") method add (line 248) | void add(T element) { method size (line 260) | int size() { method toArray (line 269) | @SuppressWarnings("unchecked") FILE: src/main/java/com/thealgorithms/sorts/StalinSort.java class StalinSort (line 3) | public class StalinSort implements SortAlgorithm { method sort (line 4) | @SuppressWarnings("unchecked") FILE: src/main/java/com/thealgorithms/sorts/StoogeSort.java class StoogeSort (line 7) | public class StoogeSort implements SortAlgorithm { method sort (line 9) | @Override method sort (line 18) | public > T[] sort(final T[] array, final int s... FILE: src/main/java/com/thealgorithms/sorts/StrandSort.java class StrandSort (line 10) | public final class StrandSort implements SortAlgorithm { method sort (line 19) | @Override method strandSort (line 33) | private static > List strandSort(Li... method merge (line 62) | private static > List merge(List... FILE: src/main/java/com/thealgorithms/sorts/SwapSort.java class SwapSort (line 10) | public class SwapSort implements SortAlgorithm { method sort (line 12) | @Override method getSmallerElementCount (line 29) | private > int getSmallerElementCount(final T[]... FILE: src/main/java/com/thealgorithms/sorts/TimSort.java class TimSort (line 10) | @SuppressWarnings({"rawtypes", "unchecked"}) method sort (line 15) | @Override method merge (line 34) | private > void merge(T[] a, final int lo, fina... FILE: src/main/java/com/thealgorithms/sorts/TopologicalSort.java class TopologicalSort (line 26) | public final class TopologicalSort { method TopologicalSort (line 27) | private TopologicalSort() { type Color (line 33) | private enum Color { class Vertex (line 42) | private static class Vertex { method Vertex (line 59) | Vertex(String label) { class Graph (line 67) | static class Graph { method addEdge (line 77) | public void addEdge(String label, String... next) { method sort (line 99) | public static LinkedList sort(Graph graph) { method sort (line 124) | private static String sort(Graph graph, Vertex u, LinkedList l... FILE: src/main/java/com/thealgorithms/sorts/TournamentSort.java class TournamentSort (line 22) | public class TournamentSort implements SortAlgorithm { method sort (line 24) | @Override method nextPowerOfTwo (line 65) | private static int nextPowerOfTwo(int n) { method winnerIndex (line 73) | private static > int winnerIndex(T[] array, in... FILE: src/main/java/com/thealgorithms/sorts/TreeSort.java class TreeSort (line 20) | public class TreeSort implements SortAlgorithm { method sort (line 22) | @Override method sort (line 27) | @Override method doTreeSortArray (line 32) | private > T[] doTreeSortArray(T[] unsortedArra... method doTreeSortList (line 54) | private > List doTreeSortList(Iterable u... method main (line 67) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/sorts/WaveSort.java class WaveSort (line 7) | public class WaveSort implements SortAlgorithm { method sort (line 15) | @Override method isWaveSorted (line 35) | public > boolean isWaveSorted(T[] array) { FILE: src/main/java/com/thealgorithms/sorts/WiggleSort.java class WiggleSort (line 18) | public class WiggleSort implements SortAlgorithm { method sort (line 20) | @Override method mapIndex (line 25) | private int mapIndex(int index, int n) { method triColorSort (line 36) | private > void triColorSort(T[] sortThis, T me... method wiggleSort (line 55) | private > T[] wiggleSort(T[] sortThis) { FILE: src/main/java/com/thealgorithms/stacks/BalancedBrackets.java class BalancedBrackets (line 19) | final class BalancedBrackets { method BalancedBrackets (line 20) | private BalancedBrackets() { method isPaired (line 31) | public static boolean isPaired(char leftBracket, char rightBracket) { method isBalanced (line 53) | public static boolean isBalanced(String brackets) { FILE: src/main/java/com/thealgorithms/stacks/CelebrityFinder.java class CelebrityFinder (line 13) | public final class CelebrityFinder { method CelebrityFinder (line 14) | private CelebrityFinder() { method findCelebrity (line 23) | public static int findCelebrity(int[][] party) { FILE: src/main/java/com/thealgorithms/stacks/DecimalToAnyUsingStack.java class DecimalToAnyUsingStack (line 14) | public final class DecimalToAnyUsingStack { method DecimalToAnyUsingStack (line 16) | private DecimalToAnyUsingStack() { method convert (line 29) | public static String convert(int number, int radix) { FILE: src/main/java/com/thealgorithms/stacks/DuplicateBrackets.java class DuplicateBrackets (line 9) | public final class DuplicateBrackets { method DuplicateBrackets (line 10) | private DuplicateBrackets() { method check (line 20) | public static boolean check(String expression) { FILE: src/main/java/com/thealgorithms/stacks/GreatestElementConstantTime.java class GreatestElementConstantTime (line 14) | public class GreatestElementConstantTime { method GreatestElementConstantTime (line 21) | public GreatestElementConstantTime() { method push (line 32) | public void push(int data) { method pop (line 52) | public void pop() { method getMaximumElement (line 68) | public Integer getMaximumElement() { FILE: src/main/java/com/thealgorithms/stacks/InfixToPostfix.java class InfixToPostfix (line 15) | public final class InfixToPostfix { method InfixToPostfix (line 17) | private InfixToPostfix() { method infix2PostFix (line 36) | public static String infix2PostFix(String infixExpression) { method precedence (line 81) | private static int precedence(char operator) { method filterBrackets (line 97) | private static String filterBrackets(String input) { FILE: src/main/java/com/thealgorithms/stacks/InfixToPrefix.java class InfixToPrefix (line 15) | public final class InfixToPrefix { method InfixToPrefix (line 17) | private InfixToPrefix() { method infix2Prefix (line 37) | public static String infix2Prefix(String infixExpression) { method precedence (line 95) | private static int precedence(char operator) { method filterBrackets (line 111) | private static String filterBrackets(String input) { FILE: src/main/java/com/thealgorithms/stacks/LargestRectangle.java class LargestRectangle (line 19) | public final class LargestRectangle { method LargestRectangle (line 21) | private LargestRectangle() { method largestRectangleHistogram (line 30) | public static String largestRectangleHistogram(int[] heights) { FILE: src/main/java/com/thealgorithms/stacks/MaximumMinimumWindow.java class MaximumMinimumWindow (line 30) | public final class MaximumMinimumWindow { method MaximumMinimumWindow (line 31) | private MaximumMinimumWindow() { method calculateMaxOfMin (line 42) | public static int[] calculateMaxOfMin(int[] arr, int n) { method main (line 101) | public static void main(String[] args) { FILE: src/main/java/com/thealgorithms/stacks/MinStackUsingSingleStack.java class MinStackUsingSingleStack (line 15) | public class MinStackUsingSingleStack { method push (line 24) | public void push(int value) { method pop (line 36) | public void pop() { method top (line 47) | public int top() { method getMin (line 59) | public int getMin() { FILE: src/main/java/com/thealgorithms/stacks/MinStackUsingTwoStacks.java class MinStackUsingTwoStacks (line 10) | public final class MinStackUsingTwoStacks { method MinStackUsingTwoStacks (line 11) | MinStackUsingTwoStacks() { method push (line 23) | public void push(int value) { method pop (line 34) | public void pop() { method top (line 45) | public int top() { method getMin (line 54) | public int getMin() { FILE: src/main/java/com/thealgorithms/stacks/NextGreaterElement.java class NextGreaterElement (line 17) | public final class NextGreaterElement { method NextGreaterElement (line 18) | private NextGreaterElement() { method findNextGreaterElements (line 29) | public static int[] findNextGreaterElements(int[] array) { FILE: src/main/java/com/thealgorithms/stacks/NextSmallerElement.java class NextSmallerElement (line 18) | public final class NextSmallerElement { method NextSmallerElement (line 19) | private NextSmallerElement() { method findNextSmallerElements (line 30) | public static int[] findNextSmallerElements(int[] array) { FILE: src/main/java/com/thealgorithms/stacks/PalindromeWithStack.java class PalindromeWithStack (line 12) | public class PalindromeWithStack { method PalindromeWithStack (line 18) | public PalindromeWithStack() { method checkPalindrome (line 31) | public boolean checkPalindrome(String string) { FILE: src/main/java/com/thealgorithms/stacks/PostfixEvaluator.java class PostfixEvaluator (line 14) | public final class PostfixEvaluator { method PostfixEvaluator (line 15) | private PostfixEvaluator() { method evaluatePostfix (line 27) | public static int evaluatePostfix(String expression) { method isOperator (line 53) | private static boolean isOperator(String token) { method applyOperator (line 65) | private static int applyOperator(String operator, int a, int b) { FILE: src/main/java/com/thealgorithms/stacks/PostfixToInfix.java class PostfixToInfix (line 19) | public final class PostfixToInfix { method PostfixToInfix (line 20) | private PostfixToInfix() { method isOperator (line 29) | public static boolean isOperator(char token) { method isValidPostfixExpression (line 43) | public static boolean isValidPostfixExpression(String postfix) { method getPostfixToInfix (line 76) | public static String getPostfixToInfix(String postfix) { FILE: src/main/java/com/thealgorithms/stacks/PrefixEvaluator.java class PrefixEvaluator (line 14) | public final class PrefixEvaluator { method PrefixEvaluator (line 15) | private PrefixEvaluator() { method evaluatePrefix (line 27) | public static int evaluatePrefix(String expression) { method isOperator (line 55) | private static boolean isOperator(String token) { method applyOperator (line 67) | private static int applyOperator(String operator, int a, int b) { FILE: src/main/java/com/thealgorithms/stacks/PrefixToInfix.java class PrefixToInfix (line 12) | public final class PrefixToInfix { method PrefixToInfix (line 13) | private PrefixToInfix() { method isOperator (line 22) | public static boolean isOperator(char token) { method getPrefixToInfix (line 33) | public static String getPrefixToInfix(String prefix) { FILE: src/main/java/com/thealgorithms/stacks/SmallestElementConstantTime.java class SmallestElementConstantTime (line 14) | public class SmallestElementConstantTime { method SmallestElementConstantTime (line 21) | public SmallestElementConstantTime() { method push (line 32) | public void push(int data) { method pop (line 52) | public void pop() { method getMinimumElement (line 68) | public Integer getMinimumElement() { FILE: src/main/java/com/thealgorithms/stacks/SortStack.java class SortStack (line 11) | public final class SortStack { method SortStack (line 12) | private SortStack() { method sortStack (line 28) | public static void sortStack(Stack stack) { method insertInSortedOrder (line 50) | private static void insertInSortedOrder(Stack stack, int elem... FILE: src/main/java/com/thealgorithms/stacks/StackPostfixNotation.java class StackPostfixNotation (line 18) | public final class StackPostfixNotation { method StackPostfixNotation (line 19) | private StackPostfixNotation() { method getOperator (line 22) | private static BiFunction getOperator(final... method performOperation (line 38) | private static void performOperation(Stack s, final String op... method consumeExpression (line 45) | private static void consumeExpression(Stack s, final String e... method postfixEvaluate (line 64) | public static int postfixEvaluate(final String exp) { FILE: src/main/java/com/thealgorithms/stacks/StackUsingTwoQueues.java class StackUsingTwoQueues (line 14) | public class StackUsingTwoQueues { method StackUsingTwoQueues (line 22) | public StackUsingTwoQueues() { method push (line 33) | public void push(int item) { method pop (line 54) | public int pop() { method peek (line 67) | public Integer peek() { method isEmpty (line 79) | public boolean isEmpty() { method size (line 88) | public int size() { FILE: src/main/java/com/thealgorithms/stacks/TrappingRainwater.java class TrappingRainwater (line 16) | public final class TrappingRainwater { method TrappingRainwater (line 18) | private TrappingRainwater() { method trap (line 22) | public static int trap(int[] height) { FILE: src/main/java/com/thealgorithms/stacks/ValidParentheses.java class ValidParentheses (line 33) | public final class ValidParentheses { method ValidParentheses (line 34) | private ValidParentheses() { method isValid (line 43) | public static boolean isValid(String s) { FILE: src/main/java/com/thealgorithms/strings/AhoCorasick.java class AhoCorasick (line 21) | public final class AhoCorasick { method AhoCorasick (line 22) | private AhoCorasick() { class Node (line 26) | private static class Node { method Node (line 33) | Node() { method getChild (line 39) | public Map getChild() { method getSuffixLink (line 43) | public Node getSuffixLink() { method setSuffixLink (line 47) | public void setSuffixLink(final Node suffixLink) { method getOutputLink (line 51) | public Node getOutputLink() { method setOutputLink (line 55) | public void setOutputLink(final Node outputLink) { method getPatternInd (line 59) | public int getPatternInd() { method setPatternInd (line 63) | public void setPatternInd(final int patternInd) { class Trie (line 69) | public static class Trie { method Trie (line 74) | public Trie(final String[] patterns) { method buildTrie (line 82) | private void buildTrie() { method initializeSuffixLinksForChildNodesOfTheRoot (line 106) | private void initializeSuffixLinksForChildNodesOfTheRoot(Queue... method buildSuffixAndOutputLinks (line 114) | private void buildSuffixAndOutputLinks() { method initializePositionByStringIndexValue (line 152) | private List> initializePositionByStringIndexValue() { method searchIn (line 161) | public List> searchIn(final String text) { method setUpStartPoints (line 191) | private void setUpStartPoints(List> positionByStringIn... method recordPatternPositions (line 212) | public void recordPatternPositions(final Node parent, final int curren... method search (line 230) | public static Map> search(final String text, fin... method convert (line 237) | private static Map> convert(final List calcShiftValues(String patt... method getShiftValue (line 178) | private static Integer getShiftValue(char c) { FILE: src/main/java/com/thealgorithms/strings/Isogram.java class Isogram (line 28) | public final class Isogram { method Isogram (line 32) | private Isogram() { method isAlphabeticIsogram (line 46) | public static boolean isAlphabeticIsogram(String str) { method isFullIsogram (line 80) | public static boolean isFullIsogram(String str) { FILE: src/main/java/com/thealgorithms/strings/Isomorphic.java class Isomorphic (line 19) | public final class Isomorphic { method Isomorphic (line 21) | private Isomorphic() { method areIsomorphic (line 31) | public static boolean areIsomorphic(String s, String t) { FILE: src/main/java/com/thealgorithms/strings/KMP.java class KMP (line 10) | public final class KMP { method KMP (line 11) | private KMP() { method kmpMatcher (line 21) | public static List kmpMatcher(final String haystack, final St... method computePrefixFunction (line 49) | private static int[] computePrefixFunction(final String p) { FILE: src/main/java/com/thealgorithms/strings/KasaiAlgorithm.java class KasaiAlgorithm (line 14) | public final class KasaiAlgorithm { method KasaiAlgorithm (line 16) | private KasaiAlgorithm() { method kasai (line 29) | public static int[] kasai(String text, int[] suffixArr) { FILE: src/main/java/com/thealgorithms/strings/LengthOfLastWord.java class LengthOfLastWord (line 21) | public class LengthOfLastWord { method lengthOfLastWord (line 34) | public int lengthOfLastWord(String s) { FILE: src/main/java/com/thealgorithms/strings/LetterCombinationsOfPhoneNumber.java class LetterCombinationsOfPhoneNumber (line 7) | public final class LetterCombinationsOfPhoneNumber { method LetterCombinationsOfPhoneNumber (line 14) | private LetterCombinationsOfPhoneNumber() { method getCombinations (line 24) | public static List getCombinations(int[] numbers) { method generateCombinations (line 39) | private static List generateCombinations(int[] numbers, int in... FILE: src/main/java/com/thealgorithms/strings/LongestCommonPrefix.java class LongestCommonPrefix (line 14) | public final class LongestCommonPrefix { method LongestCommonPrefix (line 16) | private LongestCommonPrefix() { method longestCommonPrefix (line 26) | public static String longestCommonPrefix(String[] strs) { FILE: src/main/java/com/thealgorithms/strings/LongestNonRepetitiveSubstring.java class LongestNonRepetitiveSubstring (line 9) | final class LongestNonRepetitiveSubstring { method LongestNonRepetitiveSubstring (line 10) | private LongestNonRepetitiveSubstring() { method lengthOfLongestSubstring (line 25) | public static int lengthOfLongestSubstring(String s) { FILE: src/main/java/com/thealgorithms/strings/LongestRepeatedSubstring.java class LongestRepeatedSubstring (line 15) | public final class LongestRepeatedSubstring { method LongestRepeatedSubstring (line 17) | private LongestRepeatedSubstring() { method longestRepeatedSubstring (line 26) | public static String longestRepeatedSubstring(String text) { method buildLcpArray (line 56) | static int[] buildLcpArray(String text, int[] suffixArray) { FILE: src/main/java/com/thealgorithms/strings/Lower.java class Lower (line 3) | public final class Lower { method Lower (line 4) | private Lower() { method main (line 10) | public static void main(String[] args) { method toLowerCase (line 23) | public static String toLowerCase(String s) { FILE: src/main/java/com/thealgorithms/strings/Manacher.java class Manacher (line 6) | public final class Manacher { method Manacher (line 8) | private Manacher() { method longestPalindrome (line 17) | public static String longestPalindrome(String s) { method preprocess (line 58) | private static String preprocess(String s) { FILE: src/main/java/com/thealgorithms/strings/MyAtoi.java class MyAtoi (line 6) | public final class MyAtoi { method MyAtoi (line 7) | private MyAtoi() { method myAtoi (line 25) | public static int myAtoi(String s) { FILE: src/main/java/com/thealgorithms/strings/Palindrome.java class Palindrome (line 6) | final class Palindrome { method Palindrome (line 7) | private Palindrome() { method isPalindrome (line 17) | public static boolean isPalindrome(String s) { method isPalindromeRecursion (line 28) | public static boolean isPalindromeRecursion(String s) { method isPalindromeTwoPointer (line 47) | public static boolean isPalindromeTwoPointer(String s) { FILE: src/main/java/com/thealgorithms/strings/Pangram.java class Pangram (line 8) | public final class Pangram { method Pangram (line 9) | private Pangram() { method main (line 15) | public static void main(String[] args) { method isPangramUsingSet (line 29) | public static boolean isPangramUsingSet(String s) { method isPangram (line 46) | public static boolean isPangram(String s) { method isPangram2 (line 68) | public static boolean isPangram2(String s) { FILE: src/main/java/com/thealgorithms/strings/PermuteString.java class PermuteString (line 29) | public final class PermuteString { method PermuteString (line 30) | private PermuteString() { method getPermutations (line 45) | public static Set getPermutations(String str) { method generatePermutations (line 59) | private static void generatePermutations(String str, int start, int en... method swapCharacters (line 82) | private static String swapCharacters(String str, int i, int j) { FILE: src/main/java/com/thealgorithms/strings/RabinKarp.java class RabinKarp (line 12) | public final class RabinKarp { method RabinKarp (line 13) | private RabinKarp() { method search (line 18) | public static List search(String text, String pattern) { method search (line 22) | public static List search(String text, String pattern, int q) { FILE: src/main/java/com/thealgorithms/strings/RemoveDuplicateFromString.java class RemoveDuplicateFromString (line 6) | public final class RemoveDuplicateFromString { method RemoveDuplicateFromString (line 7) | private RemoveDuplicateFromString() { method removeDuplicate (line 16) | public static String removeDuplicate(String input) { FILE: src/main/java/com/thealgorithms/strings/RemoveStars.java class RemoveStars (line 12) | public final class RemoveStars { method RemoveStars (line 14) | private RemoveStars() { method removeStars (line 17) | public static String removeStars(String s) { FILE: src/main/java/com/thealgorithms/strings/ReturnSubsequence.java class ReturnSubsequence (line 6) | public final class ReturnSubsequence { method ReturnSubsequence (line 7) | private ReturnSubsequence() { method getSubsequences (line 16) | public static String[] getSubsequences(String input) { FILE: src/main/java/com/thealgorithms/strings/ReverseString.java class ReverseString (line 8) | public final class ReverseString { method ReverseString (line 9) | private ReverseString() { method reverse (line 18) | public static String reverse(String str) { method reverse2 (line 28) | public static String reverse2(String str) { method reverse3 (line 51) | public static String reverse3(String string) { method reverseStringUsingStack (line 68) | public static String reverseStringUsingStack(String str) { method reverseStringUsingRecursion (line 95) | public static String reverseStringUsingRecursion(String str) { FILE: src/main/java/com/thealgorithms/strings/ReverseWordsInString.java class ReverseWordsInString (line 6) | public final class ReverseWordsInString { method ReverseWordsInString (line 8) | private ReverseWordsInString() { method reverseWordsInString (line 16) | public static String reverseWordsInString(final String s) { FILE: src/main/java/com/thealgorithms/strings/Rotation.java class Rotation (line 9) | public final class Rotation { method Rotation (line 10) | private Rotation() { method main (line 13) | public static void main(String[] args) { method rotation (line 29) | public static String rotation(String s, int n) { method rotation (line 40) | public static void rotation(char[] values, int n) { method reverse (line 53) | public static void reverse(char[] values, int from, int to) { FILE: src/main/java/com/thealgorithms/strings/StringCompression.java class StringCompression (line 8) | public final class StringCompression { method StringCompression (line 9) | private StringCompression() { method compress (line 17) | public static String compress(String input) { method appendCount (line 52) | public static String appendCount(String res, int count, char ch) { FILE: src/main/java/com/thealgorithms/strings/StringMatchFiniteAutomata.java class StringMatchFiniteAutomata (line 11) | public final class StringMatchFiniteAutomata { method StringMatchFiniteAutomata (line 17) | private StringMatchFiniteAutomata() { method searchPattern (line 26) | public static Set searchPattern(final String text, final Stri... method computeStateTransitionTable (line 47) | private static int[][] computeStateTransitionTable(final String patter... method getNextState (line 69) | private static int getNextState(final String pattern, final int patter... class FiniteAutomata (line 99) | private static final class FiniteAutomata { method FiniteAutomata (line 103) | private FiniteAutomata(int[][] stateTransitionTable) { method consume (line 112) | private void consume(final char input) { method getState (line 121) | private int getState() { FILE: src/main/java/com/thealgorithms/strings/SuffixArray.java class SuffixArray (line 13) | public final class SuffixArray { method SuffixArray (line 15) | private SuffixArray() { method buildSuffixArray (line 18) | public static int[] buildSuffixArray(String text) { FILE: src/main/java/com/thealgorithms/strings/TopKFrequentWords.java class TopKFrequentWords (line 19) | public final class TopKFrequentWords { method TopKFrequentWords (line 20) | private TopKFrequentWords() { method findTopKFrequentWords (line 31) | public static List findTopKFrequentWords(String[] words, int k) { FILE: src/main/java/com/thealgorithms/strings/Upper.java class Upper (line 3) | public final class Upper { method Upper (line 4) | private Upper() { method main (line 10) | public static void main(String[] args) { method toUpperCase (line 23) | public static String toUpperCase(String s) { FILE: src/main/java/com/thealgorithms/strings/WordLadder.java class WordLadder (line 13) | public final class WordLadder { method WordLadder (line 14) | private WordLadder() { method ladderLength (line 25) | public static int ladderLength(String beginWord, String endWord, Colle... FILE: src/main/java/com/thealgorithms/strings/ZAlgorithm.java class ZAlgorithm (line 6) | public final class ZAlgorithm { method ZAlgorithm (line 8) | private ZAlgorithm() { method zFunction (line 12) | public static int[] zFunction(String s) { method search (line 36) | public static int search(String text, String pattern) { FILE: src/main/java/com/thealgorithms/strings/zigZagPattern/ZigZagPattern.java class ZigZagPattern (line 3) | final class ZigZagPattern { method ZigZagPattern (line 5) | private ZigZagPattern() { method encode (line 15) | public static String encode(String s, int numRows) { FILE: src/main/java/com/thealgorithms/tree/HeavyLightDecomposition.java class HeavyLightDecomposition (line 16) | public class HeavyLightDecomposition { method HeavyLightDecomposition (line 27) | public HeavyLightDecomposition(int n) { method getPosition (line 45) | public int getPosition(int index) { method getPositionIndex (line 49) | public int getPositionIndex() { method addEdge (line 53) | public void addEdge(int u, int v) { method dfsSize (line 58) | private void dfsSize(int node, int parentNode) { method decompose (line 70) | private void decompose(int node, int head) { method buildSegmentTree (line 91) | private void buildSegmentTree(int node, int start, int end) { method updateSegmentTree (line 102) | public void updateSegmentTree(int node, int start, int end, int index,... method querySegmentTree (line 116) | public int querySegmentTree(int node, int start, int end, int left, in... method queryMaxInPath (line 129) | public int queryMaxInPath(int u, int v) { method initialize (line 149) | public void initialize(int root, int[] values) { FILE: src/test/java/com/thealgorithms/audiofilters/EMAFilterTest.java class EMAFilterTest (line 7) | public class EMAFilterTest { method testApplyBasicSignal (line 9) | @Test method testApplyEmptySignal (line 18) | @Test method testAlphaBounds (line 27) | @Test FILE: src/test/java/com/thealgorithms/audiofilters/IIRFilterTest.java class IIRFilterTest (line 10) | public class IIRFilterTest { method testConstructorValidOrder (line 12) | @Test method testConstructorInvalidOrder (line 19) | @Test method testSetCoeffsInvalidLengthA (line 25) | @Test method testSetCoeffsInvalidLengthB (line 35) | @Test method testSetCoeffsInvalidACoeffZero (line 45) | @Test method testProcessWithNoCoeffsSet (line 55) | @Test method testProcessWithCoeffsSet (line 66) | @Test FILE: src/test/java/com/thealgorithms/backtracking/AllPathsFromSourceToTargetTest.java class AllPathsFromSourceToTargetTest (line 8) | public class AllPathsFromSourceToTargetTest { method testForFirstCase (line 10) | @Test method testForSecondCase (line 22) | @Test method testForThirdCase (line 34) | @Test method testForFourthcase (line 46) | @Test FILE: src/test/java/com/thealgorithms/backtracking/ArrayCombinationTest.java class ArrayCombinationTest (line 14) | public class ArrayCombinationTest { method testCombination (line 15) | @ParameterizedTest method testCombinationThrows (line 22) | @ParameterizedTest method regularInputs (line 28) | private static Stream regularInputs() { method wrongInputs (line 37) | private static Stream wrongInputs() { FILE: src/test/java/com/thealgorithms/backtracking/CombinationSumTest.java class CombinationSumTest (line 10) | class CombinationSumTest { method norm (line 11) | private static List> norm(Iterable> x) { method sample (line 22) | @Test FILE: src/test/java/com/thealgorithms/backtracking/CombinationTest.java class CombinationTest (line 13) | public class CombinationTest { method testNegativeElement (line 15) | @Test method testNoElement (line 21) | @Test method testLengthOne (line 28) | @Test method testLengthTwo (line 35) | @Test method testCombinationsWithStrings (line 43) | @Test FILE: src/test/java/com/thealgorithms/backtracking/CrosswordSolverTest.java class CrosswordSolverTest (line 11) | public class CrosswordSolverTest { method testValidPlacement (line 13) | @Test method testPlaceAndRemoveWord (line 21) | @Test method testSolveCrossword (line 35) | @Test method testNoSolution (line 60) | @Test FILE: src/test/java/com/thealgorithms/backtracking/FloodFillTest.java class FloodFillTest (line 7) | class FloodFillTest { method testForEmptyImage (line 9) | @Test method testForSingleElementImage (line 18) | @Test method testForImageOne (line 27) | @Test method testForImageTwo (line 53) | @Test method testForImageThree (line 79) | @Test method testForSameNewAndOldColor (line 97) | @Test FILE: src/test/java/com/thealgorithms/backtracking/KnightsTourTest.java class KnightsTourTest (line 10) | public class KnightsTourTest { method setUp (line 12) | @BeforeEach method testGridInitialization (line 18) | @Test method testCountNeighbors (line 31) | @Test method testNeighbors (line 45) | @Test method testSolveSuccessful (line 52) | @Test FILE: src/test/java/com/thealgorithms/backtracking/MColoringTest.java class MColoringTest (line 12) | class MColoringTest { method testGraphColoring1 (line 14) | @Test method testGraphColoring2 (line 23) | @Test method testGraphColoring3 (line 32) | @Test method createGraph (line 41) | private ArrayList createGraph(int[][] graph) { FILE: src/test/java/com/thealgorithms/backtracking/MazeRecursionTest.java class MazeRecursionTest (line 11) | public class MazeRecursionTest { method testSolveMazeUsingFirstAndSecondStrategy (line 13) | @Test FILE: src/test/java/com/thealgorithms/backtracking/NQueensTest.java class NQueensTest (line 11) | public class NQueensTest { method testNQueens1 (line 13) | @Test method testNQueens2 (line 19) | @Test method testNQueens3 (line 25) | @Test method testNQueens4 (line 31) | @Test method testNQueens5 (line 37) | @Test method testNQueens6 (line 44) | @Test FILE: src/test/java/com/thealgorithms/backtracking/ParenthesesGeneratorTest.java class ParenthesesGeneratorTest (line 12) | public class ParenthesesGeneratorTest { method regularInputTests (line 13) | @ParameterizedTest method throwsForNegativeInputTests (line 19) | @ParameterizedTest method regularInputStream (line 25) | private static Stream regularInputStream() { method negativeInputStream (line 30) | private static Stream negativeInputStream() { FILE: src/test/java/com/thealgorithms/backtracking/PermutationTest.java class PermutationTest (line 10) | public class PermutationTest { method testNoElement (line 12) | @Test method testSingleElement (line 18) | @Test method testMultipleElements (line 24) | @Test FILE: src/test/java/com/thealgorithms/backtracking/PowerSumTest.java class PowerSumTest (line 6) | public class PowerSumTest { method testNumberZeroAndPowerZero (line 8) | @Test method testNumberHundredAndPowerTwo (line 15) | @Test method testNumberHundredAndPowerThree (line 22) | @Test FILE: src/test/java/com/thealgorithms/backtracking/SubsequenceFinderTest.java class SubsequenceFinderTest (line 11) | public class SubsequenceFinderTest { method testGenerateAll (line 13) | @ParameterizedTest method getTestCases (line 20) | static Stream getTestCases() { FILE: src/test/java/com/thealgorithms/backtracking/SudokuSolverTest.java class SudokuSolverTest (line 9) | class SudokuSolverTest { method testSolveSudokuEasyPuzzle (line 11) | @Test method testSolveSudokuHardPuzzle (line 22) | @Test method testSolveSudokuAlreadySolved (line 29) | @Test method testSolveSudokuInvalidSize (line 36) | @Test method testSolveSudokuNullBoard (line 42) | @Test method testSolveSudokuEmptyBoard (line 47) | @Test FILE: src/test/java/com/thealgorithms/backtracking/UniquePermutationTest.java class UniquePermutationTest (line 9) | public class UniquePermutationTest { method testUniquePermutationsAab (line 11) | @Test method testUniquePermutationsAbc (line 18) | @Test method testEmptyString (line 25) | @Test FILE: src/test/java/com/thealgorithms/backtracking/WordPatternMatcherTest.java class WordPatternMatcherTest (line 8) | public class WordPatternMatcherTest { method testPatternMatchingSuccess (line 10) | @Test method testPatternMatchingFailure (line 16) | @Test method testEmptyPatternAndString (line 21) | @Test method testEmptyPattern (line 26) | @Test method testEmptyString (line 31) | @Test method testLongerPatternThanString (line 36) | @Test FILE: src/test/java/com/thealgorithms/backtracking/WordSearchTest.java class WordSearchTest (line 8) | public class WordSearchTest { method test1 (line 9) | @Test method test2 (line 17) | @Test method test3 (line 25) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/BcdConversionTest.java class BcdConversionTest (line 8) | public class BcdConversionTest { method testBcdToDecimal (line 10) | @Test method testDecimalToBcd (line 16) | @Test method testBcdToDecimalZero (line 22) | @Test method testDecimalToBcdZero (line 28) | @Test method testBcdToDecimalSingleDigit (line 34) | @Test method testDecimalToBcdSingleDigit (line 40) | @Test method testBcdToDecimalMaxValue (line 46) | @Test method testDecimalToBcdMaxValue (line 52) | @Test method testBcdToDecimalInvalidHighDigit (line 58) | @Test method testDecimalToBcdInvalidValue (line 66) | @Test method testBcdToDecimalLeadingZeroes (line 74) | @Test method testDecimalToBcdLeadingZeroes (line 80) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/BinaryPalindromeCheckTest.java class BinaryPalindromeCheckTest (line 8) | public class BinaryPalindromeCheckTest { method testIsBinaryPalindrome (line 10) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/BitRotateTest.java class BitRotateTest (line 16) | public class BitRotateTest { method testRotateLeftBasic (line 20) | @Test method testRotateLeftWithCarry (line 28) | @Test method testRotateLeftShift32 (line 42) | @Test method testRotateLeftShiftNormalization (line 51) | @Test method testRotateLeftZeroShift (line 59) | @Test method testRotateRightBasic (line 68) | @Test method testRotateRightWithCarry (line 76) | @Test method testRotateRightShift32 (line 90) | @Test method testRotateRightShiftNormalization (line 99) | @Test method testRotateRightZeroShift (line 107) | @Test method testRotateLeftMaxValue (line 116) | @Test method testRotateRightMinValue (line 125) | @Test method testRotateAllOnes (line 134) | @Test method testRotateAllZeros (line 142) | @Test method testRotateLeftNegativeShift (line 152) | @Test method testRotateRightNegativeShift (line 159) | @Test method testRotateLeftRightComposition (line 168) | @Test method testRotateRightLeftComposition (line 180) | @Test method testRotateLeft31IsSameAsRotateRight1 (line 192) | @Test method testTraversals (line 199) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/BitSwapTest.java class BitSwapTest (line 11) | class BitSwapTest { method testAdditionalCases (line 13) | @ParameterizedTest(name = "Additional cases: data={0}, posA={1}, posB=... method swapDifferentBits (line 19) | @ParameterizedTest(name = "Swap different bits: data={0}, posA={1}, po... method swapSameBits (line 25) | @ParameterizedTest(name = "Swap same bits: data={0}, posA={1}, posB={2... method testEdgeCases (line 31) | @ParameterizedTest(name = "Edge cases: data={0}, posA={1}, posB={2} ->... method invalidPositionThrowsException (line 37) | @ParameterizedTest(name = "Invalid positions: data={0}, posA={1}, posB... method provideAdditionalCases (line 43) | static Stream provideAdditionalCases() { method provideDifferentBitsCases (line 47) | static Stream provideDifferentBitsCases() { method provideSameBitsCases (line 51) | static Stream provideSameBitsCases() { method provideEdgeCases (line 55) | static Stream provideEdgeCases() { method provideInvalidPositions (line 59) | static Stream provideInvalidPositions() { FILE: src/test/java/com/thealgorithms/bitmanipulation/BitwiseGCDTest.java class BitwiseGCDTest (line 9) | public class BitwiseGCDTest { method testGcdBasic (line 11) | @Test method testGcdZeroAndNonZero (line 16) | @Test method testGcdBothZero (line 22) | @Test method testGcdNegativeInputs (line 27) | @Test method testGcdIntOverload (line 34) | @Test method testGcdArray (line 39) | @Test method testGcdEmptyArray (line 45) | @Test method testGcdCoprime (line 51) | @Test method testGcdPowersOfTwo (line 56) | @Test method testGcdLargeNumbers (line 61) | @Test method testGcdEarlyExitArray (line 66) | @Test method testGcdSameNumbers (line 72) | @Test method testGcdLongMinValueBigInteger (line 77) | @Test method testGcdLongMinValueLongOverloadThrows (line 84) | @Test method testGcdWithLongMinAndOther (line 90) | @Test method testGcdWithBothLongMin (line 98) | @Test method testGcdEdgeCasesMixed (line 105) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/BooleanAlgebraGatesTest.java class BooleanAlgebraGatesTest (line 20) | class BooleanAlgebraGatesTest { method testANDGate (line 22) | @ParameterizedTest(name = "ANDGate Test Case {index}: inputs={0} -> ex... method testORGate (line 29) | @ParameterizedTest(name = "ORGate Test Case {index}: inputs={0} -> exp... method testNOTGate (line 36) | @ParameterizedTest(name = "NOTGate Test Case {index}: input={0} -> exp... method testXORGate (line 43) | @ParameterizedTest(name = "XORGate Test Case {index}: inputs={0} -> ex... method testNANDGate (line 50) | @ParameterizedTest(name = "NANDGate Test Case {index}: inputs={0} -> e... method testNORGate (line 57) | @ParameterizedTest(name = "NORGate Test Case {index}: inputs={0} -> ex... method provideAndGateTestCases (line 66) | static Stream provideAndGateTestCases() { method provideOrGateTestCases (line 72) | static Stream provideOrGateTestCases() { method provideXorGateTestCases (line 78) | static Stream provideXorGateTestCases() { method provideNandGateTestCases (line 86) | static Stream provideNandGateTestCases() { method provideNorGateTestCases (line 94) | static Stream provideNorGateTestCases() { FILE: src/test/java/com/thealgorithms/bitmanipulation/ClearLeftmostSetBitTest.java class ClearLeftmostSetBitTest (line 7) | public class ClearLeftmostSetBitTest { method testClearLeftmostSetBit (line 9) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/CountBitsFlipTest.java class CountBitsFlipTest (line 18) | @DisplayName("CountBitsFlip Tests") method exampleTenTwenty (line 21) | @Test method identicalValues (line 31) | @Test method bothZeros (line 41) | @Test method smallExample (line 48) | @Test method negativeVsZero (line 58) | @Test method minMaxLongs (line 68) | @Test method randomizedConsistency (line 78) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/CountLeadingZerosTest.java class CountLeadingZerosTest (line 7) | public class CountLeadingZerosTest { method testCountLeadingZeros (line 9) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/CountSetBitsTest.java class CountSetBitsTest (line 8) | class CountSetBitsTest { method testCountSetBitsZero (line 10) | @Test method testCountSetBitsOne (line 15) | @Test method testCountSetBitsSmallNumber (line 20) | @Test method testCountSetBitsFive (line 25) | @Test method testCountSetBitsTen (line 30) | @Test method testCountSetBitsLargeNumber (line 35) | @Test method testCountSetBitsPowerOfTwo (line 40) | @Test method testCountSetBitsNegativeInput (line 45) | @Test method testNaiveApproachMatchesOptimized (line 50) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/FindNthBitTest.java class FindNthBitTest (line 10) | public final class FindNthBitTest { method findNthBitParameterizedTest (line 19) | @ParameterizedTest method provideTestCases (line 31) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/bitmanipulation/FirstDifferentBitTest.java class FirstDifferentBitTest (line 8) | public class FirstDifferentBitTest { method testFirstDifferentBit (line 10) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/bitmanipulation/GenerateSubsetsTest.java class GenerateSubsetsTest (line 11) | class GenerateSubsetsTest { method testGenerateSubsetsWithTwoElements (line 13) | @Test method testGenerateSubsetsWithOneElement (line 26) | @Test method testGenerateSubsetsWithThreeElements (line 37) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/GrayCodeConversionTest.java class GrayCodeConversionTest (line 7) | public class GrayCodeConversionTest { method testBinaryToGray (line 9) | @Test method testGrayToBinary (line 16) | @Test method testBinaryGrayCycle (line 23) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/HammingDistanceTest.java class HammingDistanceTest (line 7) | public class HammingDistanceTest { method testHammingDistance (line 9) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/HigherLowerPowerOfTwoTest.java class HigherLowerPowerOfTwoTest (line 7) | public class HigherLowerPowerOfTwoTest { method testNextHigherPowerOfTwo (line 9) | @Test method testNextLowerPowerOfTwo (line 18) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/HighestSetBitTest.java class HighestSetBitTest (line 14) | class HighestSetBitTest { method testHighestSetBit (line 16) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/IndexOfRightMostSetBitTest.java class IndexOfRightMostSetBitTest (line 12) | class IndexOfRightMostSetBitTest { method testIndexOfRightMostSetBit (line 14) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/IsEvenTest.java class IsEvenTest (line 8) | class IsEvenTest { method testIsEven (line 9) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/IsPowerTwoTest.java class IsPowerTwoTest (line 16) | public class IsPowerTwoTest { method testIsPowerTwo (line 18) | @ParameterizedTest method provideNumbersForPowerTwo (line 28) | private static Stream provideNumbersForPowerTwo() { FILE: src/test/java/com/thealgorithms/bitmanipulation/LowestSetBitTest.java class LowestSetBitTest (line 12) | public class LowestSetBitTest { method testLowestSetBitWithPositiveNumber (line 14) | @Test method testLowestSetBitWithZero (line 20) | @Test method testLowestSetBitWithOne (line 26) | @Test method testLowestSetBitWithPowerOfTwo (line 32) | @Test method testLowestSetBitWithAllBitsSet (line 38) | @Test method testLowestSetBitWithNegativeNumber (line 44) | @Test method testLowestSetBitWithLargeNumber (line 50) | @Test method testClearLowestSetBitFor18 (line 56) | @Test method testClearLowestSetBitFor10 (line 62) | @Test method testClearLowestSetBitFor7 (line 68) | @Test method testClearLowestSetBitFor0 (line 74) | @Test method testClearLowestSetBitForNegativeNumber (line 80) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/ModuloPowerOfTwoTest.java class ModuloPowerOfTwoTest (line 9) | class ModuloPowerOfTwoTest { method testModuloPowerOfTwo (line 11) | @ParameterizedTest method testNegativeExponent (line 25) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/bitmanipulation/NextHigherSameBitCountTest.java class NextHigherSameBitCountTest (line 8) | class NextHigherSameBitCountTest { method testNextHigherSameBitCount (line 10) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/bitmanipulation/NonRepeatingNumberFinderTest.java class NonRepeatingNumberFinderTest (line 16) | class NonRepeatingNumberFinderTest { method testNonRepeatingNumberFinder (line 18) | @ParameterizedTest method testCases (line 24) | private static Arguments[] testCases() { FILE: src/test/java/com/thealgorithms/bitmanipulation/NumberAppearingOddTimesTest.java class NumberAppearingOddTimesTest (line 10) | class NumberAppearingOddTimesTest { method testFindOddOccurrence (line 16) | @ParameterizedTest method provideTestCases (line 26) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/bitmanipulation/NumbersDifferentSignsTest.java class NumbersDifferentSignsTest (line 17) | class NumbersDifferentSignsTest { method testDifferentSigns (line 19) | @ParameterizedTest method provideTestCases (line 29) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/bitmanipulation/OneBitDifferenceTest.java class OneBitDifferenceTest (line 8) | public class OneBitDifferenceTest { method testDifferByOneBit (line 10) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/bitmanipulation/OnesComplementTest.java class OnesComplementTest (line 15) | public class OnesComplementTest { method testOnesComplementAllZeroes (line 17) | @Test method testOnesComplementAllOnes (line 27) | @Test method testOnesComplementMixedBits (line 36) | @Test method testOnesComplementNullOrEmptyInputThrowsException (line 46) | @ParameterizedTest method testOnesComplementInvalidCharactersThrowsException (line 53) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/ParityCheckTest.java class ParityCheckTest (line 8) | public class ParityCheckTest { method testIsEvenParity (line 9) | @Test method testIsOddParity (line 19) | @Test method testLargeNumbers (line 29) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/ReverseBitsTest.java class ReverseBitsTest (line 10) | class ReverseBitsTest { method testReverseBits (line 12) | @ParameterizedTest method provideTestCases (line 18) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/bitmanipulation/SingleBitOperationsTest.java class SingleBitOperationsTest (line 10) | class SingleBitOperationsTest { method testFlipBit (line 12) | @ParameterizedTest method provideFlipBitTestCases (line 18) | private static Stream provideFlipBitTestCases() { method testSetBit (line 24) | @ParameterizedTest method provideSetBitTestCases (line 30) | private static Stream provideSetBitTestCases() { method testClearBit (line 38) | @ParameterizedTest method provideClearBitTestCases (line 44) | private static Stream provideClearBitTestCases() { method testGetBit (line 50) | @ParameterizedTest method provideGetBitTestCases (line 56) | private static Stream provideGetBitTestCases() { FILE: src/test/java/com/thealgorithms/bitmanipulation/SingleElementTest.java class SingleElementTest (line 10) | public final class SingleElementTest { method testFindSingleElement (line 19) | @ParameterizedTest method provideTestCases (line 30) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/bitmanipulation/SwapAdjacentBitsTest.java class SwapAdjacentBitsTest (line 8) | class SwapAdjacentBitsTest { method testSwapAdjacentBits (line 10) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/bitmanipulation/TwosComplementTest.java class TwosComplementTest (line 12) | public class TwosComplementTest { method testTwosComplementAllZeroes (line 14) | @Test method testTwosComplementAllOnes (line 22) | @Test method testTwosComplementMixedBits (line 30) | @Test method testTwosComplementSingleBit (line 38) | @Test method testTwosComplementWithLeadingZeroes (line 44) | @Test method testInvalidBinaryInput (line 51) | @Test method testEmptyInput (line 59) | @Test FILE: src/test/java/com/thealgorithms/bitmanipulation/Xs3ConversionTest.java class Xs3ConversionTest (line 10) | public class Xs3ConversionTest { method testXs3ToBinary (line 15) | @Test method testBinaryToXs3 (line 24) | @Test method testXs3ToBinaryZero (line 33) | @Test method testBinaryToXs3Zero (line 42) | @Test method testXs3ToBinarySingleDigit (line 51) | @Test method testBinaryToXs3SingleDigit (line 60) | @Test FILE: src/test/java/com/thealgorithms/ciphers/ADFGVXCipherTest.java class ADFGVXCipherTest (line 7) | class ADFGVXCipherTest { method testEncrypt (line 11) | @Test method testDecrypt (line 20) | @Test method testEmptyInput (line 29) | @Test method testShortKey (line 37) | @Test FILE: src/test/java/com/thealgorithms/ciphers/AESEncryptionTest.java class AESEncryptionTest (line 10) | public class AESEncryptionTest { method testGetSecretEncryptionKey (line 12) | @Test method testEncryptText (line 19) | @Test method testDecryptText (line 29) | @Test method testEncryptDecrypt (line 42) | @Test method testBytesToHex (line 56) | @Test FILE: src/test/java/com/thealgorithms/ciphers/AffineCipherTest.java class AffineCipherTest (line 7) | public class AffineCipherTest { method testEncryptMessage (line 9) | @Test method testEncryptDecrypt (line 19) | @Test method testSpacesHandledInEncryption (line 30) | @Test FILE: src/test/java/com/thealgorithms/ciphers/AtbashTest.java class AtbashTest (line 10) | public class AtbashTest { method testAtbashCipher (line 12) | @ParameterizedTest method cipherTestProvider (line 19) | private static Stream cipherTestProvider() { FILE: src/test/java/com/thealgorithms/ciphers/AutokeyTest.java class AutokeyCipherTest (line 7) | class AutokeyCipherTest { method autokeyEncryptTest (line 11) | @Test method autokeyDecryptTest (line 24) | @Test FILE: src/test/java/com/thealgorithms/ciphers/BaconianCipherTest.java class BaconianCipherTest (line 7) | class BaconianCipherTest { method baconianCipherEncryptTest (line 11) | @Test method baconianCipherDecryptTest (line 23) | @Test FILE: src/test/java/com/thealgorithms/ciphers/BlowfishTest.java class BlowfishTest (line 7) | class BlowfishTest { method testEncrypt (line 11) | @Test method testDecrypt (line 25) | @Test FILE: src/test/java/com/thealgorithms/ciphers/CaesarTest.java class CaesarTest (line 7) | class CaesarTest { method caesarEncryptTest (line 11) | @Test method caesarDecryptTest (line 23) | @Test method caesarBruteForce (line 35) | @Test FILE: src/test/java/com/thealgorithms/ciphers/ColumnarTranspositionCipherTest.java class ColumnarTranspositionCipherTest (line 11) | public class ColumnarTranspositionCipherTest { method setUp (line 15) | @BeforeEach method testEncryption (line 21) | @Test method testDecryption (line 30) | @Test method testLongPlainText (line 39) | @Test FILE: src/test/java/com/thealgorithms/ciphers/DESTest.java class DESTest (line 9) | public class DESTest { method setUp (line 13) | @BeforeEach method testEncrypt (line 18) | @Test method testDecrypt (line 37) | @Test FILE: src/test/java/com/thealgorithms/ciphers/DiffieHellmanTest.java class DiffieHellmanTest (line 11) | public class DiffieHellmanTest { method testCalculatePublicValue (line 14) | @ParameterizedTest method testCalculateSharedSecret (line 22) | @ParameterizedTest method provideTestData (line 30) | private static Stream provideTestData() { method createTestArgs (line 35) | private static Arguments createTestArgs(long base, long secret, long p... FILE: src/test/java/com/thealgorithms/ciphers/ECCTest.java class ECCTest (line 16) | public class ECCTest { method testEncrypt (line 22) | @Test method testDecryptWithKnownValues (line 52) | @Test method testCipherTextRandomness (line 86) | @Test method testECCEncryptionAndDecryption (line 99) | @Test FILE: src/test/java/com/thealgorithms/ciphers/ElGamalCipherTest.java class ElGamalCipherTest (line 17) | class ElGamalCipherTest { method setup (line 21) | @BeforeAll method testKeyGeneration (line 27) | @Test method testSemanticSecurity (line 44) | @Test method testEncryptDecrypt (line 63) | @ParameterizedTest method provideMessages (line 81) | static Stream provideMessages() { method testMessageZero (line 85) | @Test method testMessageMaxBound (line 95) | @Test method testMessageTooLarge (line 105) | @Test method testWrongKeyDecryption (line 112) | @Test method testHomomorphism (line 126) | @Test FILE: src/test/java/com/thealgorithms/ciphers/HillCipherTest.java class HillCipherTest (line 7) | class HillCipherTest { method hillCipherEncryptTest (line 11) | @Test method hillCipherDecryptTest (line 24) | @Test FILE: src/test/java/com/thealgorithms/ciphers/MonoAlphabeticTest.java class MonoAlphabeticTest (line 10) | public class MonoAlphabeticTest { method testEncryptDecrypt (line 13) | @ParameterizedTest method provideTestData (line 26) | private static Stream provideTestData() { FILE: src/test/java/com/thealgorithms/ciphers/OneTimePadCipherTest.java class OneTimePadCipherTest (line 10) | class OneTimePadCipherTest { method encryptAndDecryptWithRandomKeyRestoresPlaintext (line 12) | @Test method generateKeyWithNegativeLengthThrowsException (line 26) | @Test method encryptWithMismatchedKeyLengthThrowsException (line 31) | @Test method decryptWithMismatchedKeyLengthThrowsException (line 39) | @Test FILE: src/test/java/com/thealgorithms/ciphers/PermutationCipherTest.java class PermutationCipherTest (line 9) | class PermutationCipherTest { method testBasicEncryption (line 13) | @Test method testBasicDecryption (line 29) | @Test method testEncryptDecryptRoundTrip (line 42) | @Test method testSingleCharacterKey (line 56) | @Test method testLargerKey (line 71) | @Test method testExactBlockSize (line 85) | @Test method testEmptyString (line 99) | @Test method testNullString (line 114) | @Test method testStringWithSpaces (line 129) | @Test method testLowercaseConversion (line 143) | @Test method testInvalidKeyNull (line 157) | @Test method testInvalidKeyEmpty (line 168) | @Test method testInvalidKeyOutOfRange (line 179) | @Test method testInvalidKeyZero (line 190) | @Test method testInvalidKeyDuplicate (line 201) | @Test method testInvalidKeyMissingPosition (line 212) | @Test method testReverseKey (line 223) | @Test method testSpecificExampleFromDescription (line 238) | @Test method testPaddingCharacterGetter (line 256) | @Test method testLongText (line 265) | @Test method testIdentityPermutation (line 279) | @Test method testEmptyStringRemovePadding (line 294) | @Test method testBlockShorterThanKey (line 307) | @Test FILE: src/test/java/com/thealgorithms/ciphers/PlayfairTest.java class PlayfairTest (line 7) | public class PlayfairTest { method testEncryption (line 9) | @Test method testDecryption (line 18) | @Test method testEncryptionAndDecryption (line 27) | @Test FILE: src/test/java/com/thealgorithms/ciphers/PolybiusTest.java class PolybiusTest (line 7) | public class PolybiusTest { method testEncrypt (line 9) | @Test method testDecrypt (line 21) | @Test method testIsTextTheSameAfterEncryptionAndDecryption (line 33) | @Test FILE: src/test/java/com/thealgorithms/ciphers/RSATest.java class RSATest (line 9) | class RSATest { method testEncryptDecryptString (line 13) | @Test method testEncryptDecryptBigInteger (line 21) | @Test method testEmptyMessage (line 29) | @Test method testDifferentKeySizes (line 36) | @Test method testSpecialCharacters (line 57) | @Test FILE: src/test/java/com/thealgorithms/ciphers/RailFenceTest.java class RailFenceTest (line 7) | public class RailFenceTest { method testEncryption (line 9) | @Test method testDecryption (line 34) | @Test FILE: src/test/java/com/thealgorithms/ciphers/SimpleSubCipherTest.java class SimpleSubCipherTest (line 7) | class SimpleSubCipherTest { method simpleSubCipherEncryptTest (line 11) | @Test method simpleSubCipherDecryptTest (line 24) | @Test FILE: src/test/java/com/thealgorithms/ciphers/VigenereTest.java class VigenereTest (line 8) | class VigenereTest { method testVigenereEncryptDecrypt (line 12) | @Test method testWithEmptyMessage (line 24) | @Test method testWithEmptyKey (line 36) | @Test method testWithNumbersInMessage (line 45) | @Test method testLongerKeyThanMessage (line 57) | @Test method testUppercaseMessageAndKey (line 69) | @Test FILE: src/test/java/com/thealgorithms/ciphers/XORCipherTest.java class XORCipherTest (line 8) | class XORCipherTest { method xorEncryptDecryptTest (line 10) | @Test method testEmptyPlaintext (line 21) | @Test method testEmptyKey (line 33) | @Test method testShortKey (line 42) | @Test method testNonASCIICharacters (line 53) | @Test method testSameKeyAndPlaintext (line 64) | @Test method testLongPlaintextShortKey (line 75) | @Test FILE: src/test/java/com/thealgorithms/ciphers/a5/A5CipherTest.java class A5CipherTest (line 9) | public class A5CipherTest { method setUp (line 13) | @BeforeEach method testEncryptWithValidInput (line 21) | @Test method testEncryptAllOnesInput (line 32) | @Test method testEncryptAllZerosInput (line 41) | @Test FILE: src/test/java/com/thealgorithms/ciphers/a5/A5KeyStreamGeneratorTest.java class A5KeyStreamGeneratorTest (line 12) | public class A5KeyStreamGeneratorTest { method setUp (line 17) | @BeforeEach method testInitialization (line 27) | @Test method testIncrementFrameCounter (line 33) | @Test method testGetNextKeyStreamProducesDifferentOutputs (line 48) | @Test FILE: src/test/java/com/thealgorithms/ciphers/a5/LFSRTest.java class LFSRTest (line 10) | class LFSRTest { method initialize (line 28) | @Test method clock (line 54) | @Test method getClockBit (line 83) | @Test FILE: src/test/java/com/thealgorithms/compression/ArithmeticCodingTest.java class ArithmeticCodingTest (line 13) | class ArithmeticCodingTest { method testThrowsExceptionForNullOrEmptyInput (line 15) | @Test method testCompressionAndDecompressionSimple (line 24) | @Test method testSymmetryWithComplexString (line 40) | @Test method testSymmetryWithRepetitions (line 55) | @Test method testSingleCharacterString (line 70) | @Test method testCompressionOutputDemo (line 84) | @Test method testProbabilityTableCalculation (line 101) | @Test method testDecompressionWithMismatchedProbabilityTable (line 120) | @Test method testDecompressionWithValueOutsideSymbolRanges (line 138) | @Test FILE: src/test/java/com/thealgorithms/compression/BurrowsWheelerTransformTest.java class BurrowsWheelerTransformTest (line 10) | public class BurrowsWheelerTransformTest { method testTransformAndInverseBanana (line 12) | @Test method testTransformAndInverseAbracadabra (line 26) | @Test method testTransformAndInverseSixMixPixFix (line 40) | @Test method testEmptyString (line 54) | @Test method testSingleCharacter (line 66) | @Test method testTransformNull (line 78) | @Test method testInverseTransformNullString (line 83) | @Test method testInverseTransformIndexOutOfBounds (line 91) | @Test method testBWTResultHelpers (line 104) | @Test FILE: src/test/java/com/thealgorithms/compression/HuffmanCodingTest.java class HuffmanCodingTest (line 10) | class HuffmanCodingTest { method testStandardLifecycle (line 12) | @Test method testNullAndEmptyHandling (line 23) | @Test method testSingleCharacterEdgeCase (line 34) | @Test method testUnicodeAndSpecialCharacters (line 44) | @Test method testFailFastOnUnseenCharacter (line 54) | @Test method testFailFastOnInvalidBinaryCharacter (line 64) | @Test method testFailFastOnIncompleteSequence (line 76) | @Test method testImmutabilityOfDictionary (line 88) | @Test method testStressVolume (line 96) | @Test FILE: src/test/java/com/thealgorithms/compression/LZ77Test.java class LZ77Test (line 11) | class LZ77Test { method testSimpleRepeatingString (line 13) | @Test method testNoInitialRepeats (line 22) | @Test method testLongerExample (line 31) | @Test method testEmptyString (line 40) | @Test method testNullStringCompress (line 50) | @Test method testNullListDecompress (line 57) | @Test method testInvalidBufferSizes (line 64) | @Test method testAllSameCharacters (line 73) | @Test method testAllUniqueCharacters (line 85) | @Test method testSingleCharacter (line 97) | @Test method testMatchToEnd (line 107) | @Test method testSmallWindowSize (line 116) | @Test method testSmallLookaheadBuffer (line 125) | @Test method testRepeatingPatternAtEnd (line 134) | @Test method testOverlappingMatches (line 143) | @Test method testComplexPattern (line 152) | @Test method testSpecialCharacters (line 161) | @Test method testWithNumbers (line 170) | @Test method testLongRepeatingSequence (line 179) | @Test method testCompressionEffectiveness (line 191) | @Test method testMixedCase (line 206) | @Test method testDefaultParameters (line 215) | @Test FILE: src/test/java/com/thealgorithms/compression/LZ78Test.java class LZ78Test (line 10) | class LZ78Test { method testSimpleRepeatingString (line 12) | @Test method testStandardExample (line 21) | @Test method testLongerExample (line 41) | @Test method testEmptyString (line 50) | @Test method testNullStringCompress (line 60) | @Test method testNullListDecompress (line 67) | @Test method testAllSameCharacters (line 74) | @Test method testAllUniqueCharacters (line 86) | @Test method testSingleCharacter (line 103) | @Test method testTwoCharacters (line 115) | @Test method testRepeatingPairs (line 125) | @Test method testGrowingPatterns (line 137) | @Test method testDictionaryBuilding (line 146) | @Test method testSpecialCharacters (line 160) | @Test method testWithNumbers (line 169) | @Test method testLongRepeatingSequence (line 181) | @Test method testAlternatingCharacters (line 193) | @Test method testCompressionEffectiveness (line 202) | @Test method testMixedCase (line 214) | @Test method testPalindrome (line 223) | @Test method testHighlyCompressible (line 232) | @Test method testEmptyListDecompress (line 244) | @Test method testBinaryPattern (line 252) | @Test method testNestedPatterns (line 261) | @Test method testWhitespace (line 270) | @Test method testTokenStructure (line 279) | @Test FILE: src/test/java/com/thealgorithms/compression/LZWTest.java class LZWTest (line 12) | class LZWTest { method testNullAndEmptyInputs (line 14) | @Test method testCompressionAndDecompressionWithSimpleString (line 29) | @Test method testCompressionWithRepeatedChars (line 46) | @Test method testCompressionWithUniqueChars (line 55) | @Test method testSymmetry (line 64) | @Test method testInvalidCompressedData (line 80) | @Test method testDecompressionWithGapInDictionary (line 94) | @Test FILE: src/test/java/com/thealgorithms/compression/MoveToFrontTest.java class MoveToFrontTest (line 9) | public class MoveToFrontTest { method testTransformAndInverseBananaExample (line 11) | @Test method testTransformAndInverseCabaaExample (line 26) | @Test method testEmptyInput (line 41) | @Test method testEmptyAlphabet (line 54) | @Test method testSymbolNotInAlphabet (line 61) | @Test method testIndexOutOfBounds (line 67) | @Test method testTransformNull (line 77) | @Test method testInverseTransformNulls (line 84) | @Test FILE: src/test/java/com/thealgorithms/compression/RunLengthEncodingTest.java class RunLengthEncodingTest (line 7) | class RunLengthEncodingTest { method testNullInputs (line 9) | @Test method testCompressionSimple (line 18) | @Test method testCompressionWithNoRuns (line 26) | @Test method testCompressionEdgeCases (line 34) | @Test method testDecompressionSimple (line 46) | @Test method testDecompressionWithNoRuns (line 54) | @Test method testDecompressionWithMultiDigitCount (line 62) | @Test method testDecompressionEdgeCases (line 70) | @Test method testSymmetry (line 79) | @Test FILE: src/test/java/com/thealgorithms/compression/ShannonFanoTest.java class ShannonFanoTest (line 9) | class ShannonFanoTest { method testNullInput (line 11) | @Test method testSimpleString (line 17) | @Test method testExampleFromStringIssue (line 29) | @Test method testEdgeCases (line 45) | @Test method testStringWithTwoChars (line 63) | @Test FILE: src/test/java/com/thealgorithms/conversions/AffineConverterTest.java class AffineConverterTest (line 9) | public class AffineConverterTest { method setUp (line 13) | @BeforeEach method testConstructorWithValidValues (line 18) | @Test method testConstructorWithInvalidValues (line 24) | @Test method testConvertWithNegativeValues (line 29) | @Test method testConvertWithFloatingPointPrecision (line 35) | @Test method testInvert (line 41) | @Test method testInvertWithZeroSlope (line 48) | @Test method testCompose (line 54) | @Test method testMultipleCompositions (line 63) | @Test method testIdentityComposition (line 73) | @Test method testLargeInputs (line 82) | @Test FILE: src/test/java/com/thealgorithms/conversions/AnyBaseToDecimalTest.java class AnyBaseToDecimalTest (line 10) | public class AnyBaseToDecimalTest { method testConvertToDecimal (line 11) | @ParameterizedTest method testIncorrectInput (line 17) | @Test FILE: src/test/java/com/thealgorithms/conversions/AnytoAnyTest.java class AnytoAnyTest (line 8) | public class AnytoAnyTest { method testValidConversions (line 10) | @Test method testDecimalToBinary (line 18) | @Test method testBinaryToDecimal (line 24) | @Test method testOctalToDecimal (line 30) | @Test method testInvalidBases (line 36) | @Test method testLargeNumberConversion (line 43) | @Test FILE: src/test/java/com/thealgorithms/conversions/Base64Test.java class Base64Test (line 18) | class Base64Test { method testBase64Alphabet (line 20) | @Test method testStringEncoding (line 29) | @ParameterizedTest method testStringDecoding (line 37) | @ParameterizedTest method testByteArrayEncoding (line 45) | @Test method testByteArrayDecoding (line 52) | @Test method testRoundTripEncoding (line 59) | @Test method testRoundTripByteArrayEncoding (line 72) | @Test method testBinaryData (line 83) | @Test method testNullInputEncoding (line 96) | @Test method testNullInputDecoding (line 102) | @Test method testInvalidBase64Characters (line 108) | @Test method testInvalidLength (line 116) | @Test method testInvalidPaddingPosition (line 124) | @Test method testPaddingVariations (line 132) | @Test method testPaddingConsistency (line 140) | @Test method testLargeData (line 160) | @Test method testEmptyAndSingleCharacter (line 174) | @Test FILE: src/test/java/com/thealgorithms/conversions/BinaryToDecimalTest.java class BinaryToDecimalTest (line 10) | public class BinaryToDecimalTest { method testBinaryToDecimal (line 12) | @Test method testNegativeBinaryToDecimal (line 29) | @Test method testLargeBinaryToDecimal (line 39) | @Test method testNotCorrectBinaryInput (line 49) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/conversions/BinaryToHexadecimalTest.java class BinaryToHexadecimalTest (line 9) | public class BinaryToHexadecimalTest { method testBinToHex (line 11) | @ParameterizedTest method testInvalidBinaryInput (line 17) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/conversions/BinaryToOctalTest.java class BinaryToOctalTest (line 10) | public class BinaryToOctalTest { method testConvertBinaryToOctal (line 12) | @ParameterizedTest method testIncorrectInput (line 18) | @Test FILE: src/test/java/com/thealgorithms/conversions/CoordinateConverterTest.java class CoordinateConverterTest (line 9) | public class CoordinateConverterTest { method testCartesianToPolar (line 11) | @ParameterizedTest method testPolarToCartesian (line 17) | @ParameterizedTest method testCartesianToPolarInvalidInputs (line 23) | @ParameterizedTest method testPolarToCartesianInvalidInputs (line 29) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/conversions/DecimalToAnyBaseTest.java class DecimalToAnyBaseTest (line 10) | public class DecimalToAnyBaseTest { method testConvertToAnyBase (line 12) | @ParameterizedTest method testBaseOutOfRange (line 18) | @Test FILE: src/test/java/com/thealgorithms/conversions/DecimalToBinaryTest.java class DecimalToBinaryTest (line 8) | public class DecimalToBinaryTest { method testConvertUsingConventionalAlgorithm (line 10) | @ParameterizedTest method testConvertUsingBitwiseAlgorithm (line 16) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/conversions/DecimalToHexadecimalTest.java class DecimalToHexadecimalTest (line 8) | public class DecimalToHexadecimalTest { method testDecToHex (line 9) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/conversions/DecimalToOctalTest.java class DecimalToOctalTest (line 10) | class DecimalToOctalTest { method testConvertToOctal (line 11) | @ParameterizedTest method testConvertToOctalNegativeNumber (line 17) | @Test FILE: src/test/java/com/thealgorithms/conversions/EndianConverterTest.java class EndianConverterTest (line 8) | public class EndianConverterTest { method testLittleToBigEndian (line 10) | @ParameterizedTest method testBigToLittleEndian (line 23) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/conversions/HexToOctTest.java class HexToOctTest (line 7) | public class HexToOctTest { method testHexToDecimal (line 8) | @Test method testDecimalToOctal (line 16) | @Test method testHexToOctal (line 26) | @Test FILE: src/test/java/com/thealgorithms/conversions/HexaDecimalToBinaryTest.java class HexaDecimalToBinaryTest (line 11) | public class HexaDecimalToBinaryTest { method testLittleToBigEndian (line 17) | @ParameterizedTest method testBigToLittleEndian (line 33) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/conversions/HexaDecimalToDecimalTest.java class HexaDecimalToDecimalTest (line 9) | public class HexaDecimalToDecimalTest { method testValidHexaToDecimal (line 11) | @ParameterizedTest method testInvalidHexaToDecimal (line 26) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/conversions/IPConverterTest.java class IPConverterTest (line 7) | public class IPConverterTest { method generateTestIP (line 9) | private static String generateTestIP(int a, int b, int c, int d) { method generateTestBinary (line 13) | private static String generateTestBinary(int a, int b, int c, int d) { method testIpToBinary (line 17) | @Test method testBinaryToIP (line 24) | @Test FILE: src/test/java/com/thealgorithms/conversions/IPv6ConverterTest.java class IPv6ConverterTest (line 9) | public class IPv6ConverterTest { method testIpv4ToIpv6ValidInput (line 34) | @Test method testIpv6ToIpv4InvalidIPv6MappedAddress (line 40) | @Test method testIpv4ToIpv6InvalidIPv4Address (line 45) | @Test method testIpv6ToIpv4InvalidFormat (line 50) | @Test method testIpv4ToIpv6EmptyString (line 55) | @Test method testIpv6ToIpv4EmptyString (line 60) | @Test FILE: src/test/java/com/thealgorithms/conversions/IntegerToEnglishTest.java class IntegerToEnglishTest (line 7) | public class IntegerToEnglishTest { method testIntegerToEnglish (line 9) | @Test method testSmallNumbers (line 18) | @Test method testHundreds (line 26) | @Test method testThousands (line 33) | @Test method testEdgeCases (line 40) | @Test FILE: src/test/java/com/thealgorithms/conversions/IntegerToRomanTest.java class IntegerToRomanTest (line 7) | public class IntegerToRomanTest { method testIntegerToRoman (line 9) | @Test method testSmallNumbers (line 18) | @Test method testRoundNumbers (line 25) | @Test method testEdgeCases (line 34) | @Test FILE: src/test/java/com/thealgorithms/conversions/MorseCodeConverterTest.java class MorseCodeConverterTest (line 7) | public class MorseCodeConverterTest { method testTextToMorse (line 9) | @Test method testMorseToText (line 15) | @Test FILE: src/test/java/com/thealgorithms/conversions/NumberToWordsTest.java class NumberToWordsTest (line 8) | public class NumberToWordsTest { method testNullInput (line 10) | @Test method testZeroInput (line 15) | @Test method testPositiveWholeNumbers (line 20) | @Test method testNegativeWholeNumbers (line 27) | @Test method testFractionalNumbers (line 33) | @Test method testLargeNumbers (line 39) | @Test method testNegativeLargeNumbers (line 45) | @Test method testFloatingPointPrecision (line 50) | @Test method testEdgeCases (line 55) | @Test FILE: src/test/java/com/thealgorithms/conversions/OctalToBinaryTest.java class OctalToBinaryTest (line 7) | public class OctalToBinaryTest { method testConvertOctalToBinary (line 8) | @Test method testConvertOctalToBinarySingleDigit (line 16) | @Test method testConvertOctalToBinaryMultipleDigits (line 23) | @Test method testConvertOctalToBinaryWithZeroPadding (line 30) | @Test FILE: src/test/java/com/thealgorithms/conversions/OctalToDecimalTest.java class OctalToDecimalTest (line 7) | public class OctalToDecimalTest { method testConvertOctalToDecimal (line 9) | @ParameterizedTest method testIncorrectInput (line 15) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/conversions/OctalToHexadecimalTest.java class OctalToHexadecimalTest (line 7) | public class OctalToHexadecimalTest { method testCorrectInputs (line 9) | @ParameterizedTest method testIncorrectInputs (line 17) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/conversions/PhoneticAlphabetConverterTest.java class PhoneticAlphabetConverterTest (line 8) | public class PhoneticAlphabetConverterTest { method testTextToPhonetic (line 10) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/conversions/RomanToIntegerTest.java class RomanToIntegerTest (line 8) | public class RomanToIntegerTest { method testValidRomanToInteger (line 10) | @Test method testLowercaseInput (line 20) | @Test method testInvalidRomanNumerals (line 26) | @Test method testEmptyAndNullInput (line 33) | @Test FILE: src/test/java/com/thealgorithms/conversions/TemperatureConverterTest.java class TemperatureConverterTest (line 7) | class TemperatureConverterTest { method testCelsiusToFahrenheit (line 11) | @Test method testCelsiusToKelvin (line 19) | @Test method testFahrenheitToCelsius (line 26) | @Test method testFahrenheitToKelvin (line 34) | @Test method testKelvinToCelsius (line 41) | @Test method testKelvinToFahrenheit (line 48) | @Test FILE: src/test/java/com/thealgorithms/conversions/TimeConverterTest.java class TimeConverterTest (line 13) | class TimeConverterTest { method testValidConversions (line 15) | @ParameterizedTest(name = "{0} {1} -> {2} {3}") method testZeroValue (line 23) | @Test method testSameUnitConversion (line 29) | @Test method testNegativeValue (line 35) | @Test method testInvalidUnits (line 41) | @ParameterizedTest method testNullUnit (line 47) | @Test method roundTripCases (line 57) | static Stream roundTripCa... method testRoundTripConversion (line 61) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/conversions/TurkishToLatinConversionTest.java class TurkishToLatinConversionTest (line 8) | public class TurkishToLatinConversionTest { method testConvertTurkishToLatin (line 10) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/conversions/UnitConversionsTest.java class UnitConversionsTest (line 14) | public class UnitConversionsTest { method addData (line 15) | private static void addData(Stream.Builder builder, Map temperatureData() { method testTemperature (line 36) | @ParameterizedTest method testTemperatureUnits (line 43) | @Test FILE: src/test/java/com/thealgorithms/conversions/UnitsConverterTest.java class UnitsConverterTest (line 13) | public class UnitsConverterTest { method testConvertThrowsForSameUnits (line 15) | @Test method testConvertThrowsForUnknownUnits (line 22) | @Test method testAvailableUnits (line 30) | @Test method testInvertConversion (line 36) | @Test FILE: src/test/java/com/thealgorithms/conversions/WordsToNumberTest.java class WordsToNumberTest (line 9) | public class WordsToNumberTest { method testNullInput (line 11) | @Test method testStandardCases (line 17) | @Test method testLargeNumbers (line 26) | @Test method testNegativeNumbers (line 34) | @Test method testNegativeLargeNumbers (line 40) | @Test method testDecimalNumbers (line 46) | @Test method testLargeDecimalNumbers (line 53) | @Test method testCaseInsensitivity (line 65) | @Test method testInvalidInputs (line 72) | @Test method testConvertToBigDecimal (line 107) | @Test FILE: src/test/java/com/thealgorithms/datastructures/bag/BagTest.java class BagTest (line 15) | class BagTest { method testBagOperations (line 17) | @Test method testBagInitialization (line 44) | @Test method testAddElements (line 51) | @Test method testContainsMethod (line 62) | @Test method testContainsAfterAdditions (line 74) | @Test method testIterator (line 83) | @Test method testIteratorEmptyBag (line 98) | @Test method testRemoveMethodThrowsException (line 108) | @Test method testMultipleDuplicates (line 116) | @Test method testLargeNumberOfElements (line 127) | @Test method testMixedTypeElements (line 136) | @Test method testIteratorWithDuplicates (line 148) | @Test method testCollectionElements (line 163) | @Test method testIteratorConsistency (line 186) | @Test method testMultipleIterators (line 209) | @Test method testIteratorHasNextConsistency (line 228) | @Test method testIteratorNextOnEmptyBag (line 244) | @Test method testBagOrderIndependence (line 253) | @Test FILE: src/test/java/com/thealgorithms/datastructures/bloomfilter/BloomFilterTest.java class BloomFilterTest (line 14) | public class BloomFilterTest { method setUp (line 17) | @BeforeEach method testIntegerContains (line 22) | @Test method testStringContains (line 32) | @Test method testInsertAndContains (line 41) | @Test method testFalsePositive (line 51) | @Test method testMultipleInsertions (line 60) | @Test method testEmptyFilterContains (line 73) | @Test method testDifferentTypes (line 79) | @Test method testFalsePositiveAfterInsertions (line 92) | @Test method testBoundaryConditions (line 109) | @Test method testLongDataType (line 124) | @Test method testFloatDataType (line 138) | @Test method testBooleanDataType (line 154) | @Test method testListDataType (line 164) | @Test method testMapDataType (line 181) | @Test method testSetDataType (line 202) | @Test method testArrayDataType (line 219) | @Test method testSpecialFloatingPointValues (line 236) | @Test method testVerySmallBloomFilter (line 250) | @Test FILE: src/test/java/com/thealgorithms/datastructures/buffers/CircularBufferTest.java class CircularBufferTest (line 9) | class CircularBufferTest { method testInitialization (line 11) | @Test method testPutAndGet (line 18) | @Test method testOverwrite (line 36) | @Test method testEmptyBuffer (line 51) | @Test method testFullBuffer (line 57) | @Test method testIllegalArguments (line 68) | @Test method testLargeBuffer (line 77) | @Test method testPutAfterGet (line 88) | @Test method testMultipleWrapArounds (line 100) | @Test method testOverwriteMultipleTimes (line 111) | @Test method testIsEmptyAndIsFullTransitions (line 123) | @Test method testInterleavedPutAndGet (line 143) | @Test method testRepeatedNullInsertionThrows (line 155) | @Test method testFillThenEmptyThenReuseBuffer (line 163) | @Test method testPutReturnsTrueOnlyIfPreviouslyEmpty (line 185) | @Test method testOverwriteAndGetAllElementsCorrectly (line 194) | @Test method testBufferWithOneElementCapacity (line 210) | @Test method testPointerWraparoundWithExactMultipleOfCapacity (line 222) | @Test FILE: src/test/java/com/thealgorithms/datastructures/caches/FIFOCacheTest.java class FIFOCacheTest (line 13) | class FIFOCacheTest { method setUp (line 18) | @BeforeEach method testPutAndGet (line 32) | @Test method testOverwriteValue (line 38) | @Test method testExpiration (line 45) | @Test method testEvictionOnCapacity (line 53) | @Test method testEvictionListener (line 66) | @Test method testHitsAndMisses (line 77) | @Test method testSizeExcludesExpired (line 86) | @Test method testSizeIncludesFresh (line 95) | @Test method testToStringDoesNotExposeExpired (line 103) | @Test method testNullKeyGetThrows (line 113) | @Test method testPutNullKeyThrows (line 118) | @Test method testPutNullValueThrows (line 123) | @Test method testPutNegativeTTLThrows (line 128) | @Test method testBuilderNegativeCapacityThrows (line 133) | @Test method testBuilderNullEvictionListenerThrows (line 138) | @Test method testEvictionListenerExceptionDoesNotCrash (line 144) | @Test method testTtlZeroThrowsIllegalArgumentException (line 153) | @Test method testPeriodicEvictionStrategyEvictsAtInterval (line 159) | @Test method testPeriodicEvictionStrategyThrowsExceptionIfIntervalLessThanOrEqual0 (line 175) | @Test method testImmediateEvictionStrategyStrategyEvictsOnEachCall (line 182) | @Test method testBuilderThrowsExceptionIfEvictionStrategyNull (line 193) | @Test method testReturnsCorrectStrategyInstance (line 200) | @Test method testDefaultStrategyIsImmediateEvictionStrategy (line 209) | @Test method testGetEvictionStrategyIsNotNull (line 216) | @Test method testRemoveKeyRemovesExistingKey (line 223) | @Test method testRemoveKeyReturnsNullIfKeyNotPresent (line 238) | @Test method testRemoveKeyHandlesExpiredEntry (line 246) | @Test method testRemoveKeyThrowsIfKeyIsNull (line 259) | @Test method testRemoveKeyTriggersEvictionListener (line 264) | @Test method testRemoveKeyDoestNotAffectOtherKeys (line 278) | @Test method testEvictionListenerExceptionDoesNotPropagate (line 291) | @Test method testGetKeysReturnsAllFreshKeys (line 300) | @Test method testGetKeysIgnoresExpiredKeys (line 310) | @Test method testClearRemovesAllEntries (line 321) | @Test FILE: src/test/java/com/thealgorithms/datastructures/caches/LFUCacheTest.java class LFUCacheTest (line 9) | class LFUCacheTest { method testLFUCacheWithIntegerValueShouldPass (line 11) | @Test method testLFUCacheWithStringValueShouldPass (line 39) | @Test method testUpdateValueShouldPreserveFrequency (line 67) | @Test method testEvictionPolicyWhenFull (line 85) | @Test method testGetFromEmptyCacheShouldReturnNull (line 99) | @Test method testPutNullValueShouldStoreNull (line 105) | @Test method testInvalidCacheCapacityShouldThrowException (line 113) | @Test method testMultipleAccessPatterns (line 119) | @Test FILE: src/test/java/com/thealgorithms/datastructures/caches/LIFOCacheTest.java class LIFOCacheTest (line 13) | class LIFOCacheTest { method setUp (line 18) | @BeforeEach method testPutAndGet (line 32) | @Test method testOverwriteValue (line 38) | @Test method testExpiration (line 45) | @Test method testEvictionOnCapacity (line 53) | @Test method testEvictionListener (line 67) | @Test method testHitsAndMisses (line 78) | @Test method testSizeExcludesExpired (line 87) | @Test method testSizeIncludesFresh (line 96) | @Test method testToStringDoesNotExposeExpired (line 104) | @Test method testNullKeyGetThrows (line 114) | @Test method testPutNullKeyThrows (line 119) | @Test method testPutNullValueThrows (line 124) | @Test method testPutNegativeTTLThrows (line 129) | @Test method testBuilderNegativeCapacityThrows (line 134) | @Test method testBuilderNullEvictionListenerThrows (line 139) | @Test method testEvictionListenerExceptionDoesNotCrash (line 145) | @Test method testTtlZeroThrowsIllegalArgumentException (line 154) | @Test method testPeriodicEvictionStrategyEvictsAtInterval (line 160) | @Test method testPeriodicEvictionStrategyThrowsExceptionIfIntervalLessThanOrEqual0 (line 176) | @Test method testImmediateEvictionStrategyStrategyEvictsOnEachCall (line 183) | @Test method testBuilderThrowsExceptionIfEvictionStrategyNull (line 194) | @Test method testReturnsCorrectStrategyInstance (line 201) | @Test method testDefaultStrategyIsImmediateEvictionStrategy (line 210) | @Test method testGetEvictionStrategyIsNotNull (line 217) | @Test method testRemoveKeyRemovesExistingKey (line 224) | @Test method testRemoveKeyReturnsNullIfKeyNotPresent (line 239) | @Test method testRemoveKeyHandlesExpiredEntry (line 247) | @Test method testRemoveKeyThrowsIfKeyIsNull (line 260) | @Test method testRemoveKeyTriggersEvictionListener (line 265) | @Test method testRemoveKeyDoestNotAffectOtherKeys (line 279) | @Test method testEvictionListenerExceptionDoesNotPropagate (line 292) | @Test method testGetKeysReturnsAllFreshKeys (line 301) | @Test method testGetKeysIgnoresExpiredKeys (line 311) | @Test method testClearRemovesAllEntries (line 322) | @Test method testGetExpiredKeyIncrementsMissesCount (line 332) | @Test FILE: src/test/java/com/thealgorithms/datastructures/caches/LRUCacheTest.java class LRUCacheTest (line 9) | public class LRUCacheTest { method setUp (line 13) | @BeforeEach method testBasicOperations (line 18) | @Test method testEvictionPolicy (line 25) | @Test method testAccessOrder (line 45) | @Test method testUpdateExistingKey (line 63) | @Test method testNullValues (line 73) | @Test method testStringKeysAndValues (line 87) | @Test method testLongSequenceOfOperations (line 98) | @Test method testCustomObjects (line 116) | @Test FILE: src/test/java/com/thealgorithms/datastructures/caches/MRUCacheTest.java class MRUCacheTest (line 8) | public class MRUCacheTest { method putAndGetIntegerValues (line 12) | @Test method putAndGetStringValues (line 25) | @Test method nullKeysAndValues (line 38) | @Test method overCapacity (line 48) | @Test method overwriteExistingKey (line 61) | @Test method evictionOrder (line 71) | @Test method cacheHandlesLargeValues (line 92) | @Test method testEmptyCacheBehavior (line 113) | @Test FILE: src/test/java/com/thealgorithms/datastructures/caches/RRCacheTest.java class RRCacheTest (line 13) | class RRCacheTest { method setUp (line 19) | @BeforeEach method testPutAndGet (line 34) | @Test method testOverwriteValue (line 40) | @Test method testExpiration (line 47) | @Test method testEvictionOnCapacity (line 55) | @Test method testEvictionListener (line 68) | @Test method testHitsAndMisses (line 79) | @Test method testSizeExcludesExpired (line 88) | @Test method testToStringDoesNotExposeExpired (line 97) | @Test method testNullKeyGetThrows (line 107) | @Test method testPutNullKeyThrows (line 112) | @Test method testPutNullValueThrows (line 117) | @Test method testPutNegativeTTLThrows (line 122) | @Test method testBuilderNegativeCapacityThrows (line 127) | @Test method testBuilderNullRandomThrows (line 132) | @Test method testBuilderNullEvictionListenerThrows (line 138) | @Test method testEvictionListenerExceptionDoesNotCrash (line 144) | @Test method testTtlZeroThrowsIllegalArgumentException (line 153) | @Test method testPeriodicEvictionStrategyEvictsAtInterval (line 159) | @Test method testPeriodicEvictionStrategyThrowsExceptionIfIntervalLessThanOrEqual0 (line 175) | @Test method testNoEvictionStrategyEvictsOnEachCall (line 182) | @Test method testBuilderThrowsExceptionIfEvictionStrategyNull (line 193) | @Test method testReturnsCorrectStrategyInstance (line 200) | @Test method testDefaultStrategyIsNoEviction (line 209) | @Test method testGetEvictionStrategyIsNotNull (line 216) | @Test FILE: src/test/java/com/thealgorithms/datastructures/crdt/GCounterTest.java class GCounterTest (line 9) | public class GCounterTest { method increment (line 10) | @Test method merge (line 19) | @Test method compare (line 39) | @Test FILE: src/test/java/com/thealgorithms/datastructures/crdt/GSetTest.java class GSetTest (line 8) | class GSetTest { method testAddElement (line 10) | @Test method testLookup (line 21) | @Test method testCompare (line 32) | @Test method testMerge (line 46) | @Test FILE: src/test/java/com/thealgorithms/datastructures/crdt/LWWElementSetTest.java class LWWElementSetTest (line 9) | class LWWElementSetTest { method testAddElement (line 11) | @Test method testRemoveElement (line 18) | @Test method testLookupWithoutAdding (line 26) | @Test method testLookupLaterTimestampsFalse (line 32) | @Test method testLookupEarlierTimestampsTrue (line 42) | @Test method testLookupWithConcurrentTimestamps (line 52) | @Test method testMergeTwoSets (line 61) | @Test method testMergeWithConflictingTimestamps (line 76) | @Test method testRemoveOlderThanAdd (line 90) | @Test FILE: src/test/java/com/thealgorithms/datastructures/crdt/ORSetTest.java class ORSetTest (line 10) | class ORSetTest { method testContains (line 12) | @Test method testAdd (line 19) | @Test method testRemove (line 26) | @Test method testElements (line 35) | @Test method testCompareEqualSets (line 43) | @Test method testCompareDifferentSets (line 60) | @Test method testMerge (line 71) | @Test FILE: src/test/java/com/thealgorithms/datastructures/crdt/PNCounterTest.java class PNCounterTest (line 9) | public class PNCounterTest { method testIncrement (line 11) | @Test method testDecrement (line 18) | @Test method testIncrementAndDecrement (line 25) | @Test method testCompare (line 34) | @Test method testMerge (line 46) | @Test FILE: src/test/java/com/thealgorithms/datastructures/crdt/TwoPSetTest.java class TwoPSetTest (line 9) | class TwoPSetTest { method setUp (line 13) | @BeforeEach method testLookup (line 18) | @Test method testAdd (line 27) | @Test method testRemove (line 33) | @Test method testCompare (line 40) | @Test method testMerge (line 56) | @Test FILE: src/test/java/com/thealgorithms/datastructures/disjointsetunion/DisjointSetUnionBySizeTest.java class DisjointSetUnionBySizeTest (line 9) | public class DisjointSetUnionBySizeTest { method testMakeSet (line 11) | @Test method testUnionFindSet (line 20) | @Test method testFindSetOnSingleNode (line 44) | @Test method testUnionAlreadyConnectedNodes (line 51) | @Test method testMultipleMakeSets (line 71) | @Test method testPathCompression (line 90) | @Test method testMultipleDisjointSets (line 107) | @Test method testEmptyValues (line 134) | @Test FILE: src/test/java/com/thealgorithms/datastructures/disjointsetunion/DisjointSetUnionTest.java class DisjointSetUnionTest (line 9) | public class DisjointSetUnionTest { method testMakeSet (line 11) | @Test method testUnionFindSet (line 19) | @Test method testFindSetOnSingleNode (line 53) | @Test method testUnionAlreadyConnectedNodes (line 60) | @Test method testRankIncrease (line 79) | @Test method testMultipleMakeSets (line 94) | @Test method testPathCompression (line 110) | @Test method testUnionByRankSmallerToLarger (line 126) | @Test method testUnionByRankEqualRanks (line 145) | @Test method testLargeChainPathCompression (line 165) | @Test method testMultipleDisjointSets (line 191) | @Test method testEmptyValues (line 218) | @Test FILE: src/test/java/com/thealgorithms/datastructures/dynamicarray/DynamicArrayTest.java class DynamicArrayTest (line 14) | public class DynamicArrayTest { method setUp (line 18) | @BeforeEach method testGetElement (line 23) | @Test method testGetInvalidIndex (line 32) | @Test method testAddElement (line 39) | @Test method testAddAndGet (line 48) | @Test method testAddBeyondCapacity (line 58) | @Test method testPutElement (line 67) | @Test method testPutElementBeyondCapacity (line 74) | @Test method testPutAndDynamicCapacity (line 81) | @Test method testRemoveElement (line 91) | @Test method testRemoveInvalidIndex (line 101) | @Test method testRemoveComplex (line 107) | @Test method testRemoveEdgeCases (line 119) | @Test method testIsEmpty (line 133) | @Test method testSize (line 144) | @Test method testToString (line 157) | @Test method testIterator (line 165) | @Test method testStreamAsString (line 174) | @Test method testStream (line 183) | @Test method testAddToFullCapacity (line 191) | @Test method testPutWithNegativeIndex (line 202) | @Test method testGetWithNegativeIndex (line 207) | @Test method testIteratorConcurrentModification (line 212) | @Test method testIteratorRemove (line 223) | @Test method testRemoveBeyondCapacity (line 235) | @Test method testCapacityDoubling (line 248) | @Test method testContains (line 259) | @Test method testContainsWithNull (line 270) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/AStarTest.java class AStarTest (line 12) | public class AStarTest { method setUp (line 17) | @BeforeEach method testAStarFindsPath (line 27) | @Test method testAStarPathNotFound (line 34) | @Test method testAStarSameNode (line 41) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/BellmanFordTest.java class BellmanFordTest (line 17) | class BellmanFordTest { method testSimpleGraph (line 19) | @Test method testGraphWithNegativeWeights (line 48) | @Test method testSingleVertexGraph (line 62) | @Test method testLinearGraph (line 70) | @Test method testEdgeAddition (line 82) | @Test method testGraphWithZeroWeightEdges (line 95) | @Test method testLargerGraph (line 107) | @Test method testVertexAndEdgeCount (line 125) | @Test method testMultipleEdgesBetweenSameVertices (line 132) | @Test method testCompleteGraph (line 144) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/BipartiteGraphDFSTest.java class BipartiteGraphDFSTest (line 9) | public class BipartiteGraphDFSTest { method createAdjacencyList (line 12) | private ArrayList> createAdjacencyList(int numVerti... method testBipartiteGraphEvenCycle (line 26) | @Test method testBipartiteGraphOddCycle (line 34) | @Test method testBipartiteGraphDisconnected (line 42) | @Test method testBipartiteGraphSingleVertex (line 50) | @Test method testBipartiteGraphCompleteBipartite (line 58) | @Test method testBipartiteGraphNonBipartite (line 66) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/BoruvkaAlgorithmTest.java class BoruvkaAlgorithmTest (line 12) | public class BoruvkaAlgorithmTest { method testBoruvkaMSTV9E14 (line 13) | @Test method testBoruvkaMSTV2E1 (line 51) | @Test method testCompleteGraphK4 (line 70) | @Test method testNegativeVertices (line 95) | @Test method testEdgesNull (line 104) | @Test method testEdgesEmpty (line 113) | @Test method testEdgesRange (line 122) | @Test method computeTotalWeight (line 186) | int computeTotalWeight(final Iterable result) { FILE: src/test/java/com/thealgorithms/datastructures/graphs/ConnectedComponentTest.java class ConnectedComponentTest (line 18) | class ConnectedComponentTest { method testSingleConnectedComponent (line 20) | @Test method testTwoDisconnectedComponents (line 31) | @Test method testThreeDisconnectedComponents (line 43) | @Test method testSingleNodeSelfLoop (line 62) | @Test method testLinearChain (line 70) | @Test method testStarTopology (line 81) | @Test method testCompleteGraph (line 93) | @Test method testStringVertices (line 107) | @Test method testEmptyGraph (line 121) | @Test method testDepthFirstSearchBasic (line 127) | @Test method testManyIsolatedComponents (line 138) | @Test method testBidirectionalEdges (line 151) | @Test method testCyclicGraph (line 164) | @Test method testMultipleCycles (line 176) | @Test method testIntegerGraphFromMainExample (line 190) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/DialsAlgorithmTest.java class DialsAlgorithmTest (line 12) | final class DialsAlgorithmTest { method setUp (line 18) | @BeforeEach method addEdge (line 26) | private void addEdge(int u, int v, int weight) { method testSimpleGraph (line 30) | @Test method testDisconnectedNode (line 48) | @Test method testSourceIsDestination (line 60) | @Test method testMultiplePaths (line 70) | @Test method testInvalidSource (line 82) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/DijkstraAlgorithmTest.java class DijkstraAlgorithmTest (line 10) | public class DijkstraAlgorithmTest { method setUp (line 15) | @BeforeEach method testRunAlgorithm (line 32) | @Test method testGraphWithDisconnectedNodes (line 38) | @Test method testSingleVertexGraph (line 51) | @Test method testInvalidSourceVertex (line 60) | @Test method testLinearGraph (line 66) | @Test method testStarTopology (line 78) | @Test method testCompleteGraphK4 (line 94) | @Test method testDifferentSourceVertex (line 106) | @Test method testUnitWeightGraph (line 126) | @Test method testTwoVertexGraph (line 137) | @Test method testShortcutPath (line 147) | @Test method testSourceToSourceDistanceIsZero (line 161) | @Test method testLargeWeights (line 171) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/DijkstraOptimizedAlgorithmTest.java class DijkstraOptimizedAlgorithmTest (line 9) | public class DijkstraOptimizedAlgorithmTest { method setUp (line 14) | @BeforeEach method testRunAlgorithm (line 31) | @Test method testGraphWithDisconnectedNodes (line 37) | @Test method testSingleVertexGraph (line 50) | @Test method testInvalidSourceVertex (line 59) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/EdmondsBlossomAlgorithmTest.java class EdmondsBlossomAlgorithmTest (line 20) | public class EdmondsBlossomAlgorithmTest { method convertMatchingToArray (line 29) | private int[][] convertMatchingToArray(Collection matching) { method testCase1 (line 47) | @Test method testCase2 (line 61) | @Test method testCase3 (line 75) | @Test method testCaseNoMatching (line 89) | @Test method testCaseLargeGraph (line 103) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/FloydWarshallTest.java class FloydWarshallTest (line 7) | class FloydWarshallTest { method testSmallGraph (line 9) | @Test method testLargerGraph (line 22) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/FordFulkersonTest.java class FordFulkersonTest (line 7) | public class FordFulkersonTest { method testMaxFlow (line 8) | @Test method testNoFlow (line 29) | @Test method testSinglePath (line 43) | @Test method testParallelPaths (line 60) | @Test method testComplexNetwork (line 76) | @Test method testLargeNetwork (line 95) | @Test method testMultipleSourcesAndSinks (line 117) | @Test method testDisconnectedGraph (line 137) | @Test method testZeroCapacityEdge (line 152) | @Test method testAllEdgesZeroCapacity (line 168) | @Test method testCycleGraph (line 184) | @Test method testFlowWithExcessCapacity (line 201) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/HamiltonianCycleTest.java class HamiltonianCycleTest (line 7) | class HamiltonianCycleTest { method testFindHamiltonianCycleShouldReturnHamiltonianCycle (line 11) | @Test method testFindHamiltonianCycleShouldReturnInfinityArray (line 25) | @Test method testSingleVertexGraph (line 40) | @Test method testDisconnectedGraphShouldReturnInfinityArray (line 48) | @Test method testCompleteGraphShouldReturnHamiltonianCycle (line 56) | @Test method testGraphWithNoEdgesShouldReturnInfinityArray (line 70) | @Test method testLargeGraphWithHamiltonianCycle (line 85) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/JohnsonsAlgorithmTest.java class JohnsonsAlgorithmTest (line 15) | class JohnsonsAlgorithmTest { method testSimpleGraph (line 24) | @Test method testGraphWithNegativeEdges (line 35) | @Test method testNegativeWeightCycle (line 46) | @Test method testDijkstra (line 55) | @Test method testEdgeListConversion (line 67) | @Test method testReweightGraph (line 78) | @Test method testMinDistance (line 90) | @Test method testDisconnectedGraph (line 101) | @Test method testFullyConnectedGraph (line 112) | @Test method testDijkstraMultipleShortestPaths (line 123) | @Test method testGraphWithZeroWeights (line 135) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/KahnsAlgorithmTest.java class KahnsAlgorithmTest (line 9) | class KahnsAlgorithmTest { method testBasicGraph (line 11) | @Test method testGraphWithMultipleSources (line 27) | @Test method testDisconnectedGraph (line 41) | @Test method testGraphWithCycle (line 55) | @Test method testSingleNodeGraph (line 68) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/KosarajuTest.java class KosarajuTest (line 10) | public class KosarajuTest { method testFindStronglyConnectedComponents (line 14) | @Test method testFindSingleNodeSCC (line 51) | @Test method testDisconnectedGraph (line 80) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/KruskalTest.java class KruskalTest (line 13) | @SuppressWarnings({"rawtypes", "unchecked"}) method setUp (line 19) | @BeforeEach method testKruskal (line 41) | @Test method testEmptyGraph (line 74) | @Test method testSingleNodeGraph (line 81) | @Test method testGraphWithDisconnectedNodes (line 89) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/MatrixGraphsTest.java class MatrixGraphsTest (line 11) | class MatrixGraphsTest { method testGraphConstruction (line 13) | @Test method testAddEdge (line 20) | @Test method testRemoveEdge (line 34) | @Test method testVertexDoesExist (line 50) | @Test method testDepthFirstOrder (line 59) | @Test method testBreadthFirstOrder (line 77) | @Test method testToString (line 95) | @Test method testCyclicGraph (line 109) | @Test method testDisconnectedGraph (line 126) | @Test method testSingleVertexGraphDfs (line 141) | @Test method testSingleVertexGraphBfs (line 150) | @Test method testBfsLevelOrder (line 159) | @Test method testDfsStartFromDifferentVertices (line 183) | @Test method testBfsStartFromDifferentVertices (line 206) | @Test method testStarTopologyBfs (line 224) | @Test method testStarTopologyDfs (line 240) | @Test method testNegativeStartVertexDfs (line 255) | @Test method testNegativeStartVertexBfs (line 264) | @Test method testCompleteGraphKFour (line 273) | @Test method testLargerGraphTraversal (line 295) | @Test method testSelfLoop (line 318) | @Test method testLinearGraphTraversal (line 332) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/PrimMSTTest.java class PrimMSTTest (line 7) | public class PrimMSTTest { method testSimpleGraph (line 11) | @Test method testDisconnectedGraph (line 22) | @Test method testAllEqualWeightsGraph (line 33) | @Test method testSparseGraph (line 44) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/TarjansAlgorithmTest.java class TarjansAlgorithmTest (line 10) | public class TarjansAlgorithmTest { method testFindStronglyConnectedComponents (line 14) | @Test method testFindStronglyConnectedComponentsWithSingleNodes (line 41) | @Test method testGraphWithMultipleSCCs (line 68) | @Test method testDisconnectedGraph (line 89) | @Test method testSingleNodeGraph (line 111) | @Test method testEmptyGraph (line 123) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/TwoSatTest.java class TwoSatTest (line 13) | public class TwoSatTest { method testSatisfiableBasicCase (line 20) | @Test method testUnsatisfiableContradiction (line 39) | @Test method testSingleVariableTrivialSatisfiable (line 55) | @Test method testChainedDependenciesSatisfiable (line 72) | @Test method testUnsatisfiableCycle (line 95) | @Test method test6 (line 112) | @Test FILE: src/test/java/com/thealgorithms/datastructures/graphs/WelshPowellTest.java class WelshPowellTest (line 11) | class WelshPowellTest { method testSimpleGraph (line 13) | @Test method testDisconnectedGraph (line 21) | @Test method testCompleteGraph (line 29) | @Test method testComplexGraph (line 37) | @Test method testNegativeVertices (line 65) | @Test method testSelfLoop (line 70) | @Test method testInvalidVertex (line 75) | @Test method testInvalidEdgeArray (line 81) | @Test method testWithPreColoredVertex (line 86) | @Test method testLargeGraph (line 97) | @Test method testStarGraph (line 107) | @Test method isColoringValid (line 117) | private boolean isColoringValid(Graph graph, int[] colors) { method countDistinctColors (line 131) | private int countDistinctColors(int[] colors) { FILE: src/test/java/com/thealgorithms/datastructures/hashmap/hashing/GenericHashMapUsingArrayListTest.java class GenericHashMapUsingArrayListTest (line 10) | class GenericHashMapUsingArrayListTest { method testGenericHashmapWhichUsesArrayAndBothKeyAndValueAreStrings (line 12) | @Test method testGenericHashmapWhichUsesArrayAndKeyIsStringValueIsInteger (line 25) | @Test method testGenericHashmapWhichUsesArrayAndKeyIsIntegerValueIsString (line 40) | @Test method testRemoveNonExistentKey (line 54) | @Test method testRehashing (line 62) | @Test method testUpdateValueForExistingKey (line 72) | @Test method testToStringMethod (line 80) | @Test method testContainsKey (line 89) | @Test FILE: src/test/java/com/thealgorithms/datastructures/hashmap/hashing/GenericHashMapUsingArrayTest.java class GenericHashMapUsingArrayTest (line 8) | class GenericHashMapUsingArrayTest { method testGenericHashmapWhichUsesArrayAndBothKeyAndValueAreStrings (line 10) | @Test method testGenericHashmapWhichUsesArrayAndKeyIsStringValueIsInteger (line 23) | @Test method testGenericHashmapWhichUsesArrayAndKeyIsIntegerValueIsString (line 38) | @Test method testRemoveNonExistentKey (line 52) | @Test method testRehashing (line 60) | @Test method testUpdateValueForExistingKey (line 70) | @Test method testToStringMethod (line 78) | @Test method testContainsKey (line 87) | @Test method shouldThrowNullPointerExceptionForNullKey (line 97) | @Test method shouldStoreNullValueForKey (line 104) | @Test method shouldHandleCollisionWhenKeysHashToSameBucket (line 114) | @Test method shouldHandleEmptyStringAsKey (line 128) | @Test method shouldHandleEmptyStringAsValue (line 137) | @Test method shouldHandleNegativeIntegerKeys (line 146) | @Test method shouldHandleZeroAsKey (line 158) | @Test method shouldHandleStringWithSpecialCharacters (line 167) | @Test method shouldHandleLongStrings (line 176) | @Test method shouldHandleKeysOfDifferentLengths (line 193) | @ParameterizedTest method shouldHandleUpdateOnExistingKeyInCollisionBucket (line 203) | @Test method shouldHandleExactlyLoadFactorBoundary (line 219) | @Test FILE: src/test/java/com/thealgorithms/datastructures/hashmap/hashing/HashMapCuckooHashingTest.java class HashMapCuckooHashingTest (line 11) | class HashMapCuckooHashingTest { method insertKey (line 13) | @Test method getKeyIndex (line 22) | @Test method containsKey (line 31) | @Test method removeKey (line 40) | @Test method removeNone (line 51) | @Test method reHashTableIncreasesTableSize (line 63) | @Test method hashFunctionsAreDifferent (line 80) | @Test method avoidInfiniteLoops (line 88) | @Test method testLoadFactor (line 100) | @Test method testDeleteNonExistentKey (line 112) | @Test method testInsertDuplicateKey (line 127) | @Test FILE: src/test/java/com/thealgorithms/datastructures/hashmap/hashing/HashMapTest.java class HashMapTest (line 8) | public class HashMapTest { method testInsertAndSearch (line 10) | @Test method testDelete (line 23) | @Test method testDisplay (line 35) | @Test method testInsertNullKey (line 45) | @Test method testInsertNullValue (line 52) | @Test method testUpdateExistingKey (line 59) | @Test method testHandleCollisions (line 68) | @Test method testSearchInEmptyHashMap (line 81) | @Test method testDeleteNonExistentKey (line 87) | @Test method testInsertLargeNumberOfElements (line 97) | @Test method testDeleteHeadOfBucket (line 109) | @Test method testDeleteTailOfBucket (line 122) | @Test method testDeleteMiddleElementOfBucket (line 135) | @Test method testResizeHashMap (line 148) | @Test method testCollisionResolution (line 161) | @Test method testClearHashMap (line 173) | @Test FILE: src/test/java/com/thealgorithms/datastructures/hashmap/hashing/ImmutableHashMapTest.java class ImmutableHashMapTest (line 10) | class ImmutableHashMapTest { method testEmptyMap (line 12) | @Test method testPutDoesNotModifyOriginalMap (line 20) | @Test method testMultiplePuts (line 32) | @Test method testContainsKey (line 41) | @Test method testNullKey (line 49) | @Test FILE: src/test/java/com/thealgorithms/datastructures/hashmap/hashing/IntersectionTest.java class IntersectionTest (line 9) | public class IntersectionTest { method testBasicIntersection (line 11) | @Test method testNoIntersection (line 19) | @Test method testEmptyArray (line 27) | @Test method testNullArray (line 38) | @Test method testMultipleOccurrences (line 49) | @Test method testSameElements (line 57) | @Test method testLargeArrays (line 65) | @Test FILE: src/test/java/com/thealgorithms/datastructures/hashmap/hashing/LinearProbingHashMapTest.java class LinearProbingHashMapTest (line 9) | class LinearProbingHashMapTest extends MapTest { method getMap (line 11) | @Override method putNullKey (line 16) | @Test method putDuplicateKeys (line 22) | @Test method putResizeTest (line 30) | @Test method deleteNonExistentKey (line 39) | @Test method deleteAndReinsert (line 45) | @Test method resizeDown (line 55) | @Test method keysOrderTest (line 67) | @Test method stressTest (line 79) | @Test FILE: src/test/java/com/thealgorithms/datastructures/hashmap/hashing/MajorityElementTest.java class MajorityElementTest (line 10) | public class MajorityElementTest { method testMajorityWithSingleMajorityElement (line 11) | @Test method testMajorityWithMultipleMajorityElements (line 20) | @Test method testMajorityWithNoMajorityElement (line 29) | @Test method testMajorityWithEmptyArray (line 38) | @Test method testMajorityWithAllElementsSame (line 46) | @Test method testMajorityWithEvenCountAndOneMajorityElement (line 55) | @Test method testMajorityWithNoElementsEqualToHalf (line 64) | @Test method testMajorityWithLargeArray (line 72) | @Test FILE: src/test/java/com/thealgorithms/datastructures/hashmap/hashing/MapTest.java class MapTest (line 11) | abstract class MapTest { method getMap (line 12) | abstract , Value> Map getMap(); method putTest (line 14) | @Test method getTest (line 27) | @Test method deleteTest (line 45) | @Test method containsTest (line 63) | @Test method sizeTest (line 81) | @Test method keysTest (line 99) | @Test method hashTest (line 116) | @Test FILE: src/test/java/com/thealgorithms/datastructures/heaps/FibonacciHeapTest.java class FibonacciHeapTest (line 6) | public class FibonacciHeapTest { method testHeapInsertionAndMinimum (line 8) | @Test method testDeleteMinOnSingleElementHeap (line 22) | @Test method testHeapMeld (line 30) | @Test method testHeapSize (line 43) | @Test method testCountersRep (line 55) | @Test method testDeleteMinMultipleElements (line 68) | @Test method testInsertNegativeKeys (line 81) | @Test method testDeleteOnEmptyHeap (line 91) | @Test method testPotentialCalculation (line 97) | @Test FILE: src/test/java/com/thealgorithms/datastructures/heaps/GenericHeapTest.java class GenericHeapTest (line 11) | public class GenericHeapTest { method setUp (line 15) | @BeforeEach method testAddAndGet (line 20) | @Test method testRemove (line 29) | @Test method testIsEmpty (line 39) | @Test method testSize (line 46) | @Test method testUpdatePriority (line 54) | @Test method testRemoveFromEmptyHeap (line 68) | @Test method testGetFromEmptyHeap (line 74) | @Test method testUpdatePriorityForNonExistentItem (line 80) | @Test FILE: src/test/java/com/thealgorithms/datastructures/heaps/HeapElementTest.java class HeapElementTest (line 10) | class HeapElementTest { method testConstructorAndGetters (line 12) | @Test method testConstructorWithNullInfo (line 19) | @Test method testToString (line 26) | @Test method testEquals (line 35) | @Test method testHashCode (line 47) | @Test FILE: src/test/java/com/thealgorithms/datastructures/heaps/IndexedPriorityQueueTest.java class IndexedPriorityQueueTest (line 15) | public class IndexedPriorityQueueTest { class Node (line 22) | static class Node { method Node (line 26) | Node(String id, int prio) { method toString (line 31) | @Override class NodeWithEquals (line 38) | static class NodeWithEquals { method NodeWithEquals (line 42) | NodeWithEquals(String id, int prio) { method equals (line 47) | @Override method hashCode (line 57) | @Override method toString (line 62) | @Override method newNodePQ (line 68) | private static IndexedPriorityQueue newNodePQ() { method testOfferPollWithIntegersComparableMode (line 76) | @Test method testPeekAndIsEmpty (line 95) | @Test method testRemoveSpecificElement (line 109) | @Test method testContainsAndClear (line 129) | @Test method testDecreaseKeyMovesUp (line 151) | @Test method testIncreaseKeyMovesDown (line 172) | @Test method testChangeKeyChoosesDirectionAutomatically (line 193) | @Test method testDirectMutationWithoutChangeKeyDoesNotReheapByDesign (line 213) | @Test method testDuplicateEqualsElementsAreSupportedIdentityMap (line 239) | @Test method testGrowByManyInserts (line 261) | @Test method testRemoveHeadAndMiddleAndTail (line 284) | @Test method testInvalidInitialCapacityThrows (line 322) | @Test method testChangeKeyOnMissingElementThrows (line 327) | @Test method testDecreaseKeyOnMissingElementThrows (line 335) | @Test method testIncreaseKeyOnMissingElementThrows (line 343) | @Test FILE: src/test/java/com/thealgorithms/datastructures/heaps/KthElementFinderTest.java class KthElementFinderTest (line 7) | public class KthElementFinderTest { method testFindKthLargest (line 8) | @Test method testFindKthSmallest (line 14) | @Test FILE: src/test/java/com/thealgorithms/datastructures/heaps/LeftistHeapTest.java class LeftistHeapTest (line 6) | public class LeftistHeapTest { method testIsEmpty (line 8) | @Test method testInsertAndExtractMin (line 20) | @Test method testMerge (line 35) | @Test method testInOrderTraversal (line 58) | @Test method testMultipleExtractions (line 70) | @Test FILE: src/test/java/com/thealgorithms/datastructures/heaps/MaxHeapTest.java class MaxHeapTest (line 18) | class MaxHeapTest { method setUp (line 22) | @BeforeEach method testConstructorWithNullList (line 29) | @Test method testConstructorWithEmptyList (line 34) | @Test method testConstructorWithNullElements (line 40) | @Test method testInsertElement (line 47) | @Test method testInsertNullElement (line 54) | @Test method testGetElementAtIndex (line 59) | @Test method testGetElementAtInvalidIndex (line 66) | @Test method testDeleteElement (line 72) | @Test method testDeleteElementAtInvalidIndex (line 79) | @Test method testDeleteFromEmptyHeap (line 85) | @Test method testExtractMax (line 91) | @Test method testExtractMaxFromEmptyHeap (line 103) | @Test method testHeapOrder (line 109) | @Test method testSizeAndEmpty (line 127) | @Test FILE: src/test/java/com/thealgorithms/datastructures/heaps/MedianFinderTest.java class MedianFinderTest (line 7) | public class MedianFinderTest { method testMedianMaintenance (line 8) | @Test FILE: src/test/java/com/thealgorithms/datastructures/heaps/MergeKSortedArraysTest.java class MergeKSortedArraysTest (line 10) | public class MergeKSortedArraysTest { method testMergeKArrays (line 12) | @ParameterizedTest method provideTestCases (line 18) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/datastructures/heaps/MinHeapTest.java class MinHeapTest (line 15) | class MinHeapTest { method setUp (line 19) | @BeforeEach method testConstructorWithNullList (line 26) | @Test method testConstructorWithEmptyList (line 31) | @Test method testConstructorWithNullElements (line 37) | @Test method testInsertElement (line 44) | @Test method testInsertNullElement (line 51) | @Test method testGetElementAtIndex (line 56) | @Test method testGetElementAtInvalidIndex (line 63) | @Test method testDeleteElement (line 69) | @Test method testDeleteElementAtInvalidIndex (line 76) | @Test method testDeleteFromEmptyHeap (line 82) | @Test method testExtractMin (line 88) | @Test method testExtractMinFromEmptyHeap (line 100) | @Test method testHeapOrder (line 106) | @Test method testSizeAndEmpty (line 124) | @Test FILE: src/test/java/com/thealgorithms/datastructures/heaps/MinPriorityQueueTest.java class MinPriorityQueueTest (line 6) | public class MinPriorityQueueTest { method testInsertAndPeek (line 8) | @Test method testDelete (line 18) | @Test method testIsEmpty (line 29) | @Test method testIsFull (line 38) | @Test method testHeapSort (line 49) | @Test method testPeekEmptyQueue (line 67) | @Test method testDeleteEmptyQueue (line 73) | @Test method testInsertWhenFull (line 79) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/CircleLinkedListTest.java class CircleLinkedListTest (line 10) | public class CircleLinkedListTest { method setUp (line 14) | @BeforeEach method testInitialSize (line 19) | @Test method testAppendAndSize (line 24) | @Test method testRemove (line 34) | @Test method testRemoveInvalidIndex (line 47) | @Test method testToStringEmpty (line 56) | @Test method testToStringAfterRemoval (line 61) | @Test method testSingleElement (line 71) | @Test method testNullElement (line 81) | @Test method testCircularReference (line 86) | @Test method testClear (line 100) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/CircularDoublyLinkedListTest.java class CircularDoublyLinkedListTest (line 9) | public class CircularDoublyLinkedListTest { method setUp (line 13) | @BeforeEach method testInitialSize (line 18) | @Test method testAppendAndSize (line 23) | @Test method testRemove (line 33) | @Test method testRemoveInvalidIndex (line 51) | @Test method testToStringEmpty (line 60) | @Test method testSingleElement (line 65) | @Test method testNullAppend (line 77) | @Test method testRemoveLastPosition (line 82) | @Test method testRemoveFromEmptyThrows (line 92) | @Test method testRepeatedAppendAndRemove (line 97) | @Test method testToStringAfterMultipleRemoves (line 111) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/CountSinglyLinkedListRecursionTest.java class CountSinglyLinkedListRecursionTest (line 10) | public class CountSinglyLinkedListRecursionTest { method setUp (line 14) | @BeforeEach method testCountEmptyList (line 19) | @Test method testCountSingleElementList (line 25) | @Test method testCountMultipleElements (line 32) | @Test method testCountWithDuplicateElements (line 41) | @Test method testCountAfterClearingList (line 52) | @Test method testCountOnVeryLargeList (line 62) | @Test method testCountOnListWithNegativeNumbers (line 72) | @Test method testCountIsConsistentWithoutModification (line 81) | @Test method testCountAllSameValues (line 91) | @Test method testCountAfterEachInsert (line 100) | @Test method testEdgeCaseNoElements (line 112) | @Test method testCountAfterInsertAndClear (line 118) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/CreateAndDetectLoopTest.java class CreateAndDetectLoopTest (line 9) | public class CreateAndDetectLoopTest { method setUp (line 13) | @BeforeEach method testDetectLoopNoLoop (line 30) | @Test method testCreateAndDetectLoopLoopExists (line 36) | @Test method testCreateLoopInvalidPosition (line 45) | @Test method testCreateLoopSelfLoop (line 54) | @Test method testCreateLoopNoChangeForNonExistentPositions (line 63) | @Test method testMultipleNodesWithNoLoop (line 72) | @Test method testHeadToTailLoop (line 78) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/CursorLinkedListTest.java class CursorLinkedListTest (line 10) | class CursorLinkedListTest { method setUp (line 13) | @BeforeEach method testAppendAndGet (line 18) | @Test method testIndexOf (line 31) | @Test method testRemove (line 43) | @Test method testRemoveByIndex (line 56) | @Test method testRemoveFirstElement (line 68) | @Test method testRemoveLastElement (line 79) | @Test method testNullHandling (line 90) | @Test method testEmptyList (line 97) | @Test method testMemoryLimitExceeded (line 103) | @Test method testSingleElementOperations (line 113) | @Test method testDuplicateElements (line 125) | @Test method testRemoveByIndexEdgeCases (line 141) | @Test method testRemoveByIndexLastElement (line 162) | @Test method testConsecutiveOperations (line 175) | @Test method testMemoryReclamation (line 194) | @Test method testSpecialCharacters (line 216) | @Test method testLargeIndices (line 232) | @Test method testSequentialRemovalByIndex (line 241) | @Test method testAppendAfterRemoval (line 260) | @Test method testPerformanceWithManyOperations (line 273) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/FlattenMultilevelLinkedListTest.java class FlattenMultilevelLinkedListTest (line 15) | final class FlattenMultilevelLinkedListTest { method toList (line 19) | private List toList(FlattenMultilevelLinkedList.Node head) { method testFlattenNullList (line 29) | @Test method testFlattenSingleLevelList (line 35) | @Test method testFlattenComplexMultilevelList (line 51) | @Test method testFlattenWithEmptyChildLists (line 87) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/MergeKSortedLinkedListTest.java class MergeKSortedLinkedListTest (line 10) | class MergeKSortedLinkedListTest { method testMergeKLists (line 12) | @Test method testMergeEmptyLists (line 27) | @Test method testMergeSingleList (line 37) | @Test method testMergeListsOfDifferentLengths (line 50) | @Test method testMergeSingleElementLists (line 65) | @Test method getListValues (line 83) | private int[] getListValues(Node head) { method testMergeWithNullListsInArray (line 94) | @Test method testMergeWithDuplicateValues (line 109) | @Test method testMergeWithZeroLength (line 124) | @Test method testMergeWithNegativeNumbers (line 134) | @Test method testMergeIdenticalLists (line 148) | @Test method testMergeAlreadySortedSequence (line 163) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/MergeSortedArrayListTest.java class MergeSortedArrayListTest (line 12) | class MergeSortedArrayListTest { method testMergeTwoSortedLists (line 14) | @Test method testMergeWithEmptyList (line 26) | @Test method testMergeWithBothEmptyLists (line 38) | @Test method testMergeWithDuplicateElements (line 49) | @Test method testMergeWithNegativeAndPositiveNumbers (line 61) | @Test method testMergeThrowsExceptionOnNullInput (line 73) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/MergeSortedSinglyLinkedListTest.java class MergeSortedSinglyLinkedListTest (line 8) | class MergeSortedSinglyLinkedListTest { method testMergeTwoSortedLists (line 10) | @Test method testMergeWithEmptyListA (line 24) | @Test method testMergeWithEmptyListB (line 36) | @Test method testMergeWithBothEmptyLists (line 48) | @Test method testMergeWithDuplicateValues (line 57) | @Test method testMergeThrowsExceptionOnNullInput (line 73) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/MiddleOfLinkedListTest.java class MiddleOfLinkedListTest (line 9) | public class MiddleOfLinkedListTest { method listOf (line 11) | private static SinglyLinkedListNode listOf(int firstValue, int... rema... method middleNodeOddLength (line 22) | @Test method middleNodeEvenLengthReturnsSecondMiddle (line 29) | @Test method middleNodeSingleElement (line 36) | @Test method middleNodeTwoElementsReturnsSecond (line 43) | @Test method middleNodeNullHead (line 50) | @Test method middleNodeDoesNotModifyListStructure (line 55) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/QuickSortLinkedListTest.java class QuickSortLinkedListTest (line 13) | public class QuickSortLinkedListTest { method testSortEmptyList (line 15) | @Test method testSortSingleNodeList (line 24) | @Test method testSortAlreadySorted (line 35) | @Test method testSortReverseOrderedList (line 49) | @Test method testSortWithDuplicates (line 63) | @Test method testSortMultipleElementsList (line 77) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/ReverseKGroupTest.java class ReverseKGroupTest (line 12) | public class ReverseKGroupTest { method testReverseKGroupWithEmptyList (line 14) | @Test method testReverseKGroupWithSingleNodeList (line 20) | @Test method testReverseKGroupWithKEqualTo2 (line 29) | @Test method testReverseKGroupWithKEqualTo3 (line 51) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/RotateSinglyLinkedListsTest.java class RotateSinglyLinkedListsTest (line 12) | public class RotateSinglyLinkedListsTest { method createLinkedList (line 17) | private SinglyLinkedListNode createLinkedList(int[] values) { method linkedListToString (line 32) | private String linkedListToString(SinglyLinkedListNode head) { method testRotateRightEmptyList (line 45) | @Test method testRotateRightSingleNodeList (line 51) | @Test method testRotateRightMultipleElementsList (line 59) | @Test method testRotateRightFullRotation (line 67) | @Test method testRotateRightZeroRotation (line 75) | @Test method testRotateRightByListLength (line 83) | @Test method testRotateRightByMultipleOfListLength (line 91) | @Test method testRotateRightLongerList (line 98) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/SearchSinglyLinkedListRecursionTest.java class SearchSinglyLinkedListRecursionTest (line 9) | public class SearchSinglyLinkedListRecursionTest { method setUp (line 13) | @BeforeEach method testSearchInEmptyList (line 18) | @Test method testSearchSingleElementListFound (line 24) | @Test method testSearchSingleElementListNotFound (line 31) | @Test method testSearchMultipleElementsListFound (line 38) | @Test method testSearchMultipleElementsListFirstElement (line 47) | @Test method testSearchMultipleElementsListLastElement (line 56) | @Test method testSearchMultipleElementsListNotFound (line 65) | @Test method testSearchNegativeValues (line 74) | @Test method testSearchZeroValue (line 84) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/SinglyLinkedListTest.java class SinglyLinkedListTest (line 13) | public class SinglyLinkedListTest { method createSampleList (line 20) | private SinglyLinkedList createSampleList(int length) { method detectLoop (line 34) | @Test method middle (line 54) | @Test method swap (line 72) | @Test method clear (line 82) | @Test method search (line 91) | @Test method deleteNth (line 98) | @Test method reverseList (line 106) | @Test method reverseListNullPointer (line 133) | @Test method reverseListTest (line 147) | @Test method recursiveReverseList (line 169) | void recursiveReverseList() { method recursiveReverseListNullPointer (line 184) | @Test method recursiveReverseListTest (line 197) | @Test method readWithEnhancedForLoopTest (line 215) | @Test method toStringTest (line 232) | @Test method toStringForEmptyListTest (line 241) | @Test method countTest (line 247) | @Test method countForEmptyListTest (line 255) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/SkipListTest.java class SkipListTest (line 13) | class SkipListTest { method setUp (line 17) | @BeforeEach method testAdd (line 22) | @Test method testGet (line 33) | @Test method testContains (line 40) | @Test method testRemoveFromHead (line 49) | @Test method testRemoveFromTail (line 62) | @Test method testSortedOrderOnBaseLevel (line 75) | @Test method testAddDuplicates (line 86) | @Test method testClearViaRemovals (line 96) | @Test method createSkipList (line 109) | private SkipList createSkipList() { FILE: src/test/java/com/thealgorithms/datastructures/lists/SortedLinkedListTest.java class SortedLinkedListTest (line 10) | public class SortedLinkedListTest { method setUp (line 14) | @BeforeEach method testInsertIntoEmptyList (line 19) | @Test method testInsertInSortedOrder (line 25) | @Test method testInsertDuplicateValues (line 33) | @Test method testDeleteHeadElement (line 41) | @Test method testDeleteTailElement (line 50) | @Test method testDeleteMiddleElement (line 59) | @Test method testDeleteNonexistentElement (line 68) | @Test method testDeleteFromSingleElementList (line 75) | @Test method testDeleteFromEmptyList (line 82) | @Test method testSearchInEmptyList (line 87) | @Test method testSearchForExistingElement (line 92) | @Test method testSearchForNonexistentElement (line 100) | @Test method testIsEmptyOnEmptyList (line 108) | @Test method testIsEmptyOnNonEmptyList (line 113) | @Test method testIsEmptyAfterInsertion (line 119) | @Test method testIsEmptyAfterDeletion (line 125) | @Test method testInsertNegativeNumbers (line 132) | @Test method testInsertMixedPositiveAndNegativeNumbers (line 140) | @Test method testMultipleDeletesUntilEmpty (line 148) | @Test method testDeleteDuplicateValuesOnlyDeletesOneInstance (line 160) | @Test method testSearchOnListWithDuplicates (line 173) | @Test method testToStringOnEmptyList (line 182) | @Test method testDeleteAllDuplicates (line 187) | @Test method testInsertAfterDeletion (line 199) | @Test FILE: src/test/java/com/thealgorithms/datastructures/lists/TortoiseHareAlgoTest.java class TortoiseHareAlgoTest (line 8) | class TortoiseHareAlgoTest { method testAppendAndToString (line 10) | @Test method testGetMiddleOdd (line 19) | @Test method testGetMiddleEven (line 30) | @Test method testEmptyList (line 40) | @Test FILE: src/test/java/com/thealgorithms/datastructures/queues/CircularQueueTest.java class CircularQueueTest (line 9) | class CircularQueueTest { method testEnQueue (line 11) | @Test method testDeQueue (line 22) | @Test method testIsEmpty (line 34) | @Test method testIsFull (line 43) | @Test method testPeek (line 54) | @Test method testDeleteQueue (line 64) | @Test method testEnQueueOnFull (line 74) | @Test method testDeQueueOnEmpty (line 83) | @Test method testPeekOnEmpty (line 89) | @Test method testSize (line 95) | @Test method testCircularWrapAround (line 107) | @Test method testEnQueueDeQueueMultipleTimes (line 123) | @Test method testMultipleWrapArounds (line 139) | @Test method testSizeDuringOperations (line 153) | @Test FILE: src/test/java/com/thealgorithms/datastructures/queues/DequeTest.java class DequeTest (line 10) | class DequeTest { method testAddFirst (line 12) | @Test method testAddLast (line 21) | @Test method testPollFirst (line 30) | @Test method testPollLast (line 40) | @Test method testIsEmpty (line 50) | @Test method testPeekFirstEmpty (line 58) | @Test method testPeekLastEmpty (line 64) | @Test method testPollFirstEmpty (line 70) | @Test method testPollLastEmpty (line 76) | @Test method testToString (line 82) | @Test method testAlternatingAddRemove (line 91) | @Test method testSizeAfterOperations (line 103) | @Test method testNullValues (line 116) | @Test method testMultipleAddFirst (line 125) | @Test method testMultipleAddLast (line 137) | @Test method testSingleElementOperations (line 149) | @Test method testSingleElementPollLast (line 162) | @Test method testMixedNullAndValues (line 171) | @Test method testSymmetricOperations (line 185) | @Test FILE: src/test/java/com/thealgorithms/datastructures/queues/GenericArrayListQueueTest.java class GenericArrayListQueueTest (line 10) | class GenericArrayListQueueTest { method testAdd (line 12) | @Test method testPeek (line 20) | @Test method testPoll (line 33) | @Test method testIsEmpty (line 46) | @Test method testClearQueueAndReuse (line 57) | @Test method testOrderMaintained (line 71) | @Test method testVariousDataTypes (line 83) | @Test method testEmptyPollAndPeekBehavior (line 94) | @Test FILE: src/test/java/com/thealgorithms/datastructures/queues/LinkedQueueTest.java class LinkedQueueTest (line 12) | class LinkedQueueTest { method setUp (line 16) | @BeforeEach method testIsEmptyOnNewQueue (line 21) | @Test method testEnqueueAndSize (line 26) | @Test method testDequeueOnSingleElementQueue (line 37) | @Test method testDequeueMultipleElements (line 44) | @Test method testDequeueOnEmptyQueue (line 56) | @Test method testPeekFrontOnEmptyQueue (line 61) | @Test method testPeekRearOnEmptyQueue (line 66) | @Test method testPeekFront (line 71) | @Test method testPeekRear (line 82) | @Test method testPeekAtPosition (line 93) | @Test method testPeekAtInvalidPosition (line 104) | @Test method testClearQueue (line 114) | @Test method testIterator (line 125) | @Test method testToString (line 140) | @Test method testEnqueueAfterDequeue (line 149) | @Test method testQueueMaintainsOrder (line 163) | @Test method testSizeAfterOperations (line 176) | @Test method testQueueToStringOnEmptyQueue (line 193) | @Test method testEnqueueNull (line 198) | @Test method testIteratorOnEmptyQueue (line 203) | @Test FILE: src/test/java/com/thealgorithms/datastructures/queues/PriorityQueuesTest.java class PriorityQueuesTest (line 6) | class PriorityQueuesTest { method testPQInsertion (line 8) | @Test method testPQDeletion (line 22) | @Test method testPQExtra (line 37) | @Test method testInsertUntilFull (line 59) | @Test method testRemoveFromEmpty (line 69) | @Test method testInsertDuplicateValues (line 75) | @Test method testSizeAfterInsertAndRemove (line 88) | @Test method testInsertAndRemoveAll (line 102) | @Test FILE: src/test/java/com/thealgorithms/datastructures/queues/QueueByTwoStacksTest.java class QueueByTwoStacksTest (line 10) | public class QueueByTwoStacksTest { method setUp (line 14) | @BeforeEach method testEmptyQueue (line 19) | @Test method testEnqueue (line 24) | @Test method testDequeue (line 31) | @Test method testInterleavedOperations (line 41) | @Test method testQueueSize (line 51) | @Test method testEmptyQueueException (line 63) | @Test method testDequeueAllElements (line 68) | @Test method testLargeNumberOfOperations (line 79) | @Test method testRefillDuringDequeue (line 91) | @Test method testAlternatingPutAndGet (line 103) | @Test method testSizeStability (line 115) | @Test method testMultipleEmptyDequeues (line 123) | @Test method testQueueWithStrings (line 129) | @Test FILE: src/test/java/com/thealgorithms/datastructures/queues/QueueTest.java class QueueTest (line 7) | public class QueueTest { method setUp (line 12) | @BeforeEach method testQueueInsertion (line 17) | @Test method testQueueRemoval (line 29) | @Test method testPeekFrontAndRear (line 49) | @Test method testQueueIsEmptyAndIsFull (line 62) | @Test method testQueueSize (line 79) | @Test method testQueueToString (line 92) | @Test method testQueueThrowsExceptionOnEmptyPeek (line 111) | @Test method testQueueThrowsExceptionOnRemoveFromEmptyQueue (line 117) | @Test method testQueueCapacityException (line 122) | @Test method testCircularBehavior (line 128) | @Test method testMixedInsertRemoveOperations (line 151) | @Test method testSingleElementOperations (line 172) | @Test method testNullValueHandling (line 188) | @Test method testStringDataType (line 205) | @Test method testLargerCapacityQueue (line 216) | @Test method testQueueCapacityOne (line 239) | @Test method testQueueWraparoundIndexing (line 259) | @Test method testQueueStateAfterMultipleCycles (line 284) | @Test method testQueueConsistencyAfterOperations (line 308) | @Test FILE: src/test/java/com/thealgorithms/datastructures/queues/ReverseQueueRecursionTest.java class ReverseQueueRecursionTest (line 10) | class ReverseQueueRecursionTest { method testReverseMultipleElements (line 11) | @Test method testReverseSingleElement (line 26) | @Test method testReverseEmptyQueue (line 35) | @Test method testReverseStringQueue (line 42) | @Test FILE: src/test/java/com/thealgorithms/datastructures/queues/SlidingWindowMaximumTest.java class SlidingWindowMaximumTest (line 10) | public class SlidingWindowMaximumTest { method testMaxSlidingWindow (line 12) | @ParameterizedTest method provideTestCases (line 18) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/datastructures/queues/TokenBucketTest.java class TokenBucketTest (line 8) | public class TokenBucketTest { method testRateLimiter (line 10) | @Test method testRateLimiterWithExceedingRequests (line 21) | @Test method testRateLimiterMultipleRefills (line 35) | @Test method testRateLimiterEmptyBucket (line 51) | @Test method testRateLimiterWithHighRefillRate (line 58) | @Test method testRateLimiterWithSlowRequests (line 75) | @Test FILE: src/test/java/com/thealgorithms/datastructures/stacks/NodeStackTest.java class NodeStackTest (line 11) | class NodeStackTest { method setUp (line 16) | @BeforeEach method testPush (line 22) | @Test method testPop (line 31) | @Test method testPopOnEmptyStack (line 41) | @Test method testPeek (line 48) | @Test method testPeekOnEmptyStack (line 59) | @Test method testIsEmpty (line 66) | @Test method testSize (line 77) | @Test method testPushPopWithNull (line 91) | @Test method testLifoBehavior (line 105) | @Test method testPeekDoesNotModifyStack (line 121) | @Test method testMixedOperations (line 137) | @Test method testStackWithDuplicates (line 157) | @Test method testDifferentDataTypes (line 173) | @Test method testStateConsistencyAfterExceptions (line 190) | @Test method testSingleElementStack (line 221) | @Test method testToString (line 236) | @Test FILE: src/test/java/com/thealgorithms/datastructures/stacks/ReverseStackTest.java class ReverseStackTest (line 10) | class ReverseStackTest { method testReverseNullStack (line 12) | @Test method testReverseEmptyStack (line 17) | @Test method testReverseSingleElementStack (line 24) | @Test method testReverseTwoElementStack (line 32) | @Test method testReverseMultipleElementsStack (line 43) | @Test method testReverseStackAndVerifySize (line 59) | @Test FILE: src/test/java/com/thealgorithms/datastructures/stacks/StackArrayListTest.java class StackArrayListTest (line 8) | class StackArrayListTest { method setUp (line 12) | @BeforeEach method testPushAndPop (line 17) | @Test method testPeek (line 28) | @Test method testIsEmpty (line 38) | @Test method testMakeEmpty (line 47) | @Test method testSize (line 57) | @Test method testPopEmptyStackThrowsException (line 67) | @Test method testPeekEmptyStackThrowsException (line 72) | @Test method testMixedOperations (line 77) | @Test method testMultipleMakeEmptyCalls (line 95) | @Test FILE: src/test/java/com/thealgorithms/datastructures/stacks/StackArrayTest.java class StackArrayTest (line 7) | class StackArrayTest { method setUp (line 11) | @BeforeEach method testPushAndPop (line 16) | @Test method testPeek (line 31) | @Test method testIsEmpty (line 44) | @Test method testResizeOnPush (line 53) | @Test method testResizeOnPop (line 69) | @Test method testMakeEmpty (line 86) | @Test method testPopEmptyStackThrowsException (line 97) | @Test method testPeekEmptyStackThrowsException (line 102) | @Test method testConstructorWithInvalidSizeThrowsException (line 107) | @Test method testDefaultConstructor (line 113) | @Test method testToString (line 122) | @Test method testSingleElementOperations (line 130) | @Test method testAlternatingPushPop (line 141) | @Test method testPushNullElements (line 157) | @Test method testWithDifferentDataTypes (line 175) | @Test FILE: src/test/java/com/thealgorithms/datastructures/stacks/StackOfLinkedListTest.java class StackOfLinkedListTest (line 11) | public class StackOfLinkedListTest { method setUp (line 15) | @BeforeEach method testPushAndPeek (line 20) | @Test method testPop (line 30) | @Test method testPopEmptyStack (line 42) | @Test method testPeekEmptyStack (line 47) | @Test method testIsEmpty (line 52) | @Test method testToString (line 63) | @Test method testMultiplePushesAndPops (line 72) | @Test method testGetSize (line 85) | @Test method testSizeAfterClearingStack (line 95) | @Test method testSequentialPushAndPop (line 109) | @Test method testPushZeroAndNegativeValues (line 122) | @Test method testPushDuplicateValues (line 133) | @Test method testPushAfterEmptyingStack (line 145) | @Test method testPeekDoesNotModifyStack (line 159) | @Test method testAlternatingPushAndPop (line 173) | @Test method testToStringWithSingleElement (line 189) | @Test method testStackIntegrity (line 195) | @Test method testMixedDataTypes (line 211) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/AVLTreeTest.java class AVLTreeTest (line 11) | public class AVLTreeTest { method setUp (line 14) | @BeforeEach method testInsert (line 19) | @Test method testSearch (line 27) | @Test method testDeleteLeafNode (line 35) | @Test method testDeleteNodeWithOneChild (line 44) | @Test method testDeleteNodeWithTwoChildren (line 53) | @Test method testReturnBalance (line 65) | @Test method testInsertAndRebalance (line 77) | @Test method testComplexInsertionAndDeletion (line 87) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/BSTFromSortedArrayTest.java class BSTFromSortedArrayTest (line 9) | public class BSTFromSortedArrayTest { method testNullArray (line 10) | @Test method testEmptyArray (line 16) | @Test method testSingleElementArray (line 22) | @Test method testCreateBSTFromSmallArray (line 28) | @Test method testCreateBSTFromLongerArray (line 34) | @Test method testShouldNotCreateBSTFromNonSortedArray (line 41) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/BSTIterativeTest.java class BSTIterativeTest (line 9) | public class BSTIterativeTest { method testBSTIsCorrectlyConstructedFromOneNode (line 10) | @Test method testBSTIsCorrectlyCleanedAndEmpty (line 18) | @Test method testBSTIsCorrectlyCleanedAndNonEmpty (line 36) | @Test method testBSTIsCorrectlyConstructedFromMultipleNodes (line 50) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/BSTRecursiveGenericTest.java class BSTRecursiveGenericTest (line 18) | class BSTRecursiveGenericTest { method setUp (line 26) | @BeforeEach method testAddAndFindInteger (line 35) | @Test method testAddAndFindString (line 49) | @Test method testRemoveElements (line 61) | @Test method testInorderTraversal (line 76) | @Test method testPreorderTraversal (line 88) | @Test method testPostorderTraversal (line 100) | @Test method testInorderSort (line 112) | @Test method testPrettyDisplay (line 124) | @Test method testEmptyTree (line 140) | @Test method testSingleNodeTree (line 150) | @Test method testDuplicateInsertions (line 161) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/BSTRecursiveTest.java class BSTRecursiveTest (line 9) | public class BSTRecursiveTest { method testBSTIsCorrectlyConstructedFromOneNode (line 10) | @Test method testBSTIsCorrectlyCleanedAndEmpty (line 18) | @Test method testBSTIsCorrectlyCleanedAndNonEmpty (line 36) | @Test method testBSTIsCorrectlyConstructedFromMultipleNodes (line 50) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/BTreeTest.java class BTreeTest (line 11) | public class BTreeTest { method testInsertSearchDelete (line 13) | @Test method testEmptyTreeSearch (line 37) | @Test method testDuplicateInsertions (line 43) | @Test method testDeleteNonExistentKey (line 58) | @Test method testComplexInsertDelete (line 68) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/BinaryTreeTest.java class BinaryTreeTest (line 9) | public class BinaryTreeTest { method testInsertAndFind (line 11) | @Test method testRemove (line 25) | @Test method testRemoveReturnValue (line 45) | @Test method testTraversalMethods (line 58) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/BinaryTreeToStringTest.java class BinaryTreeToStringTest (line 9) | public class BinaryTreeToStringTest { method testTreeToStringBasic (line 11) | @Test method testSingleNodeTree (line 27) | @Test method testComplexTreeStructure (line 38) | @Test method testNullTree (line 52) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/BoundaryTraversalTest.java class BoundaryTraversalTest (line 12) | public class BoundaryTraversalTest { method testNullRoot (line 14) | @Test method testSingleNodeTree (line 20) | @Test method testCompleteBinaryTree (line 38) | @Test method testBoundaryTraversal (line 61) | @Test method testLeftSkewedTree (line 80) | @Test method testRightSkewedTree (line 99) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/CeilInBinarySearchTreeTest.java class CeilInBinarySearchTreeTest (line 9) | public class CeilInBinarySearchTreeTest { method testRootNull (line 11) | @Test method testKeyPresentRootIsCeil (line 16) | @Test method testKeyPresentLeafIsCeil (line 22) | @Test method testKeyAbsentRootIsCeil (line 28) | @Test method testKeyAbsentLeafIsCeil (line 34) | @Test method testKeyAbsentLeftMostNodeIsCeil (line 40) | @Test method testKeyAbsentCeilIsNull (line 46) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/CentroidDecompositionTest.java class CentroidDecompositionTest (line 17) | class CentroidDecompositionTest { method testSingleNode (line 19) | @Test method testTwoNodes (line 30) | @Test method testLinearTree (line 46) | @Test method testBalancedBinaryTree (line 58) | @Test method testStarTree (line 83) | @Test method testCompleteTree (line 99) | @Test method testLargerTree (line 124) | @Test method testPathGraph (line 143) | @Test method testInvalidEmptyTree (line 155) | @Test method testInvalidNegativeNodes (line 160) | @Test method testInvalidNullEdges (line 165) | @Test method testInvalidEdgeCount (line 170) | @Test method testInvalidEdgeFormat (line 177) | @Test method testInvalidNodeInEdge (line 183) | @Test method testInvalidNodeQuery (line 189) | @Test method testToString (line 199) | @Test method testAdjacencyListConstructor (line 211) | @Test method testNullAdjacencyList (line 227) | @Test method testEmptyAdjacencyList (line 232) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/CheckBinaryTreeIsValidBSTTest.java class CheckBinaryTreeIsValidBSTTest (line 11) | public class CheckBinaryTreeIsValidBSTTest { method testRootNull (line 12) | @Test method testOneNode (line 17) | @Test method testBinaryTreeIsBST (line 30) | @Test method testBinaryTreeWithDuplicatedNodesIsNotBST (line 43) | @Test method testBinaryTreeIsNotBST (line 56) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/CheckIfBinaryTreeBalancedTest.java class CheckIfBinaryTreeBalancedTest (line 13) | public class CheckIfBinaryTreeBalancedTest { method testRootNull (line 14) | @Test method testOneNode (line 20) | @Test method testBinaryTreeIsBalancedEqualSubtreeHeights (line 34) | @Test method testBinaryTreeIsBalancedWithDifferentHeights (line 48) | @Test method testBinaryTreeNotBalanced (line 62) | @Test method testBinaryTreeNotBalancedBecauseLeftTreeNotBalanced (line 78) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/CheckTreeIsSymmetricTest.java class CheckTreeIsSymmetricTest (line 11) | public class CheckTreeIsSymmetricTest { method testRootNull (line 13) | @Test method testSingleNodeTree (line 18) | @Test method testSymmetricTree (line 24) | @Test method testNonSymmetricTree (line 30) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/CreateBinaryTreeFromInorderPreorderTest.java class CreateBinaryTreeFromInorderPreorderTest (line 10) | public class CreateBinaryTreeFromInorderPreorderTest { method testOnNullArraysShouldReturnNullTree (line 11) | @Test method testOnEmptyArraysShouldCreateNullTree (line 22) | @Test method testOnSingleNodeTreeShouldCreateCorrectTree (line 37) | @Test method testOnRightSkewedTreeShouldCreateCorrectTree (line 52) | @Test method testOnLeftSkewedTreeShouldCreateCorrectTree (line 67) | @Test method testOnNormalTreeShouldCreateCorrectTree (line 82) | @Test method checkTree (line 97) | private static void checkTree(Integer[] preorder, Integer[] inorder, B... FILE: src/test/java/com/thealgorithms/datastructures/trees/InorderTraversalTest.java class InorderTraversalTest (line 12) | public class InorderTraversalTest { method testNullRoot (line 13) | @Test method testRecursiveInorder (line 26) | @Test method testRecursiveInorderNonBalanced (line 44) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/KDTreeTest.java class KDTreeTest (line 7) | public class KDTreeTest { method pointOf (line 9) | KDTree.Point pointOf(int x, int y) { method findMin (line 13) | @Test method delete (line 29) | @Test method findNearest (line 46) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/LazySegmentTreeTest.java class LazySegmentTreeTest (line 7) | public class LazySegmentTreeTest { method build (line 9) | @Test method update (line 18) | @Test method get (line 37) | @Test method updateAndGet (line 47) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/LevelOrderTraversalTest.java class LevelOrderTraversalTest (line 12) | public class LevelOrderTraversalTest { method testRootNull (line 13) | @Test method testSingleNodeTree (line 18) | @Test method testLevelOrderTraversalCompleteTree (line 31) | @Test method testLevelOrderTraversalDifferentHeight (line 46) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/PostOrderTraversalTest.java class PostOrderTraversalTest (line 14) | public class PostOrderTraversalTest { method testNullRoot (line 15) | @Test method testPostOrder (line 28) | @Test method testPostOrderNonBalanced (line 46) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/PreOrderTraversalTest.java class PreOrderTraversalTest (line 12) | public class PreOrderTraversalTest { method testNullRoot (line 13) | @Test method testRecursivePreOrder (line 26) | @Test method testRecursivePreOrderNonBalanced (line 44) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/QuadTreeTest.java class QuadTreeTest (line 7) | public class QuadTreeTest { method testNullPointInsertIntoQuadTree (line 12) | @Test method testInsertIntoQuadTree (line 17) | @Test method testInsertIntoQuadTreeAndSubDivide (line 26) | @Test method testQueryInQuadTree (line 38) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/SameTreesCheckTest.java class SameTreesCheckTest (line 11) | public class SameTreesCheckTest { method testBothRootsAreNull (line 12) | @Test method testOneRootIsNull (line 17) | @Test method testSingleNodeTreesAreSame (line 23) | @Test method testSameTreesIsSuccessful (line 37) | @Test method testSameTreesFails (line 51) | @Test method testTreesWithDifferentStructure (line 63) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/SplayTreeTest.java class SplayTreeTest (line 14) | public class SplayTreeTest { method testTraversal (line 16) | @ParameterizedTest method testSearch (line 24) | @ParameterizedTest method testDelete (line 31) | @ParameterizedTest method testSearchNonExistent (line 40) | @ParameterizedTest method testDeleteNonExistent (line 47) | @ParameterizedTest method testDeleteThrowsExceptionForEmptyTree (line 55) | @ParameterizedTest method testInsertThrowsExceptionForDuplicateKeys (line 62) | @ParameterizedTest method testSearchInEmptyTree (line 69) | @ParameterizedTest method traversalStrategies (line 76) | private static Stream traversalStrategies() { method valuesToTest (line 81) | private static Stream valuesToTest() { method nonExistentValues (line 85) | private static Stream nonExistentValues() { method createComplexTree (line 89) | private SplayTree createComplexTree() { FILE: src/test/java/com/thealgorithms/datastructures/trees/ThreadedBinaryTreeTest.java class ThreadedBinaryTreeTest (line 17) | public class ThreadedBinaryTreeTest { method testInorderTraversalSimple (line 19) | @Test method testInorderWithDuplicates (line 36) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/TreapTest.java class TreapTest (line 9) | public class TreapTest { method searchAndFound (line 11) | @Test method searchAndNotFound (line 24) | @Test method lowerBound (line 37) | @Test method size (line 50) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/TreeTestUtils.java class TreeTestUtils (line 7) | public final class TreeTestUtils { method TreeTestUtils (line 8) | private TreeTestUtils() { method createTree (line 17) | public static Node createTree(final Integer[] values) { FILE: src/test/java/com/thealgorithms/datastructures/trees/TrieTest.java class TrieTest (line 11) | public class TrieTest { method setUp (line 16) | @BeforeEach method testInsertAndSearchBasic (line 21) | @Test method testSearchNonExistentWord (line 28) | @Test method testInsertAndSearchMultipleWords (line 34) | @Test method testDeleteExistingWord (line 46) | @Test method testDeleteNonExistentWord (line 54) | @Test method testInsertAndSearchPrefix (line 60) | @Test method testCountWords (line 72) | @Test method testStartsWithPrefix (line 78) | @Test method testCountWordsWithPrefix (line 84) | @Test method createTrie (line 90) | private Trie createTrie() { FILE: src/test/java/com/thealgorithms/datastructures/trees/VerticalOrderTraversalTest.java class VerticalOrderTraversalTest (line 12) | public class VerticalOrderTraversalTest { method testRootNull (line 13) | @Test method testSingleNodeTree (line 18) | @Test method testVerticalTraversalCompleteTree (line 31) | @Test method testVerticalTraversalDifferentHeight (line 46) | @Test FILE: src/test/java/com/thealgorithms/datastructures/trees/ZigzagTraversalTest.java class ZigzagTraversalTest (line 12) | public class ZigzagTraversalTest { method testRootNull (line 13) | @Test method testSingleNodeTree (line 18) | @Test method testZigzagTraversalCompleteTree (line 31) | @Test method testZigzagTraversalDifferentHeight (line 46) | @Test FILE: src/test/java/com/thealgorithms/devutils/entities/ProcessDetailsTest.java class ProcessDetailsTest (line 15) | class ProcessDetailsTest { method setUp (line 20) | @BeforeEach method testConstructorWithPriority (line 27) | @Test method testConstructorWithoutPriority (line 40) | @Test method testGetProcessId (line 53) | @Test method testGetArrivalTime (line 59) | @Test method testGetBurstTime (line 65) | @Test method testGetWaitingTime (line 71) | @Test method testGetTurnAroundTimeTime (line 78) | @Test method testGetPriority (line 85) | @Test method testSetProcessId (line 91) | @Test method testSetArrivalTime (line 105) | @Test method testSetBurstTime (line 119) | @Test method testSetWaitingTime (line 133) | @Test method testSetTurnAroundTimeTime (line 147) | @Test method testCompleteProcessLifecycle (line 161) | @Test method testProcessWithMinimumValues (line 178) | @Test method testProcessWithMaximumValues (line 189) | @Test method testProcessModificationAfterCreation (line 200) | @Test method testMultipleProcessesIndependence (line 221) | @Test method testConstructorParameterOrder (line 248) | @Test method testTypicalSchedulingScenario (line 259) | @Test FILE: src/test/java/com/thealgorithms/divideandconquer/BinaryExponentiationTest.java class BinaryExponentiationTest (line 7) | public class BinaryExponentiationTest { method testCalculatePower (line 9) | @Test method testPower (line 24) | @Test FILE: src/test/java/com/thealgorithms/divideandconquer/ClosestPairTest.java class ClosestPairTest (line 8) | public class ClosestPairTest { method testBuildLocation (line 10) | @Test method testXPartition (line 19) | @Test method testYPartition (line 38) | @Test method testBruteForce (line 57) | @Test FILE: src/test/java/com/thealgorithms/divideandconquer/CountingInversionsTest.java class CountingInversionsTest (line 7) | public class CountingInversionsTest { method testCountInversions (line 9) | @Test method testNoInversions (line 15) | @Test method testSingleElement (line 21) | @Test method testAllInversions (line 27) | @Test method testEmptyArray (line 33) | @Test method testArrayWithDuplicates (line 39) | @Test method testLargeArray (line 46) | @Test method testArrayWithAllSameElements (line 57) | @Test FILE: src/test/java/com/thealgorithms/divideandconquer/MedianOfTwoSortedArraysTest.java class MedianOfTwoSortedArraysTest (line 10) | public class MedianOfTwoSortedArraysTest { method testFindMedianSortedArrays (line 12) | @ParameterizedTest method provideTestCases (line 18) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/divideandconquer/SkylineAlgorithmTest.java class SkylineAlgorithmTest (line 9) | public class SkylineAlgorithmTest { method setUp (line 13) | @BeforeEach method testProduceSubSkyLinesSinglePoint (line 18) | @Test method testProduceSubSkyLinesTwoPoints (line 31) | @Test method testProduceSubSkyLinesMultiplePoints (line 45) | @Test method testProduceFinalSkyLine (line 65) | @Test method testXComparator (line 89) | @Test FILE: src/test/java/com/thealgorithms/divideandconquer/StrassenMatrixMultiplicationTest.java class StrassenMatrixMultiplicationTest (line 7) | class StrassenMatrixMultiplicationTest { method strassenMatrixMultiplicationTest2x2 (line 14) | @Test method strassenMatrixMultiplicationTest4x4 (line 23) | @Test method strassenMatrixMultiplicationTestNegetiveNumber4x4 (line 32) | @Test FILE: src/test/java/com/thealgorithms/divideandconquer/TilingProblemTest.java class TilingProblemTest (line 7) | public class TilingProblemTest { method testTilingSize2 (line 9) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/AbbreviationTest.java class AbbreviationTest (line 10) | public class AbbreviationTest { method testAbbreviation (line 12) | @ParameterizedTest method provideTestCases (line 18) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/dynamicprogramming/AllConstructTest.java class AllConstructTest (line 11) | public class AllConstructTest { method testAllConstructBasic (line 13) | @Test method testAllConstructMultipleWays (line 20) | @Test method testAllConstructNoWays (line 27) | @Test method testAllConstructEmptyTarget (line 34) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/AssignmentUsingBitmaskTest.java class AssignmentUsingBitmaskTest (line 10) | public final class AssignmentUsingBitmaskTest { method testCountNoOfWays (line 12) | @Test method testNoPossibleAssignments (line 23) | @Test method testSinglePersonMultipleTasks (line 34) | @Test method testMultiplePeopleSingleTask (line 45) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/BoardPathTest.java class BoardPathTest (line 10) | public class BoardPathTest { method testBpR (line 12) | @ParameterizedTest method testBpRS (line 18) | @ParameterizedTest method testBpIS (line 24) | @ParameterizedTest method provideTestCases (line 30) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/dynamicprogramming/BoundaryFillTest.java class BoundaryFillTest (line 9) | public class BoundaryFillTest { method setUp (line 13) | @BeforeEach method testGetPixel (line 18) | @Test method testPutPixel (line 25) | @Test method testBoundaryFill (line 34) | @Test method testBoundaryFillEdgeCase (line 45) | @Test method testBoundaryFillInvalidCoordinates (line 56) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/BruteForceKnapsackTest.java class BruteForceKnapsackTest (line 7) | public class BruteForceKnapsackTest { method testKnapSackBasicCase (line 9) | @Test method testKnapSackNoItems (line 20) | @Test method testKnapSackZeroCapacity (line 31) | @Test method testKnapSackSingleItemFits (line 42) | @Test method testKnapSackSingleItemDoesNotFit (line 53) | @Test method testKnapSackAllItemsFit (line 64) | @Test method testKnapSackNoneFit (line 75) | @Test method testKnapSackSomeItemsFit (line 86) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/CatalanNumberTest.java class CatalanNumberTest (line 7) | public class CatalanNumberTest { method testCatalanNumber (line 9) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/ClimbStairsTest.java class ClimbStairsTest (line 7) | public class ClimbStairsTest { method climbStairsTestForTwo (line 9) | @Test method climbStairsTestForZero (line 14) | @Test method climbStairsTestForOne (line 19) | @Test method climbStairsTestForFive (line 24) | @Test method climbStairsTestForThree (line 29) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/CoinChangeTest.java class CoinChangeTest (line 7) | public class CoinChangeTest { method testChangeBasic (line 9) | @Test method testChangeNoCoins (line 17) | @Test method testChangeNoAmount (line 25) | @Test method testChangeImpossibleAmount (line 33) | @Test method testMinimumCoinsBasic (line 41) | @Test method testMinimumCoinsNoCoins (line 49) | @Test method testMinimumCoinsNoAmount (line 57) | @Test method testMinimumCoinsImpossibleAmount (line 65) | @Test method testMinimumCoinsExactAmount (line 73) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/CountFriendsPairingTest.java class CountFriendsPairingTest (line 8) | public class CountFriendsPairingTest { method testSmallCase (line 10) | @Test method testMismatchSequence (line 18) | @Test method testLargerCase (line 26) | @Test method testEdgeCaseSingleElement (line 34) | @Test method testEmptySequence (line 42) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/DPTest.java class DPTest (line 7) | public class DPTest { method testSumLessThanMinimumFaceValue (line 9) | @Test method testTwoDiceWithSumEqualToTwo (line 16) | @Test method testTwoDiceWithSumThree (line 23) | @Test method testThreeDiceWithSumEight (line 30) | @Test method testTwoDiceWithSumFive (line 37) | @Test method testThreeDiceWithSumFive (line 44) | @Test method testEdgeCaseZeroSum (line 51) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/DamerauLevenshteinDistanceTest.java class DamerauLevenshteinDistanceTest (line 14) | class DamerauLevenshteinDistanceTest { method testNullFirstString (line 16) | @Test method testNullSecondString (line 22) | @Test method testBothNullStrings (line 28) | @Test method testIdenticalStrings (line 34) | @Test method testEmptyStrings (line 43) | @Test method testSingleInsertion (line 51) | @Test method testSingleDeletion (line 59) | @Test method testSingleSubstitution (line 67) | @Test method testAdjacentTransposition (line 75) | @Test method testCAtoABC (line 83) | @Test method testNonAdjacentTransposition (line 92) | @Test method testMultipleOperations (line 99) | @Test method testCompletelyDifferentStrings (line 107) | @Test method testRepeatedCharacters (line 114) | @Test method testSymmetry (line 122) | @Test method testCaseSensitivity (line 129) | @Test method testSingleCharacterStrings (line 136) | @Test method testLongStrings (line 144) | @Test method testTriangleInequality (line 156) | @Test method testSpecialCharacters (line 171) | @Test method testNumericStrings (line 179) | @Test method testUnicodeCharacters (line 187) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/EditDistanceTest.java class EditDistanceTest (line 10) | public class EditDistanceTest { method testMinDistance (line 12) | @ParameterizedTest method testEditDistanceBothEmptyStrings (line 18) | @Test method testEditDistanceOneEmptyString (line 23) | @Test method testEditDistanceOneEmptyStringMemoization (line 29) | @Test method testEditDistanceEqualStrings (line 38) | @Test method testEditDistanceEqualStringsMemoization (line 44) | @Test method testEditDistanceOneCharacterDifference (line 71) | @Test method testEditDistanceOneCharacterDifferenceMemoization (line 78) | @Test method testEditDistanceGeneralCases (line 91) | @Test method testEditDistanceGeneralCasesMemoization (line 98) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/EggDroppingTest.java class EggDroppingTest (line 7) | public class EggDroppingTest { method hasMultipleEggSingleFloor (line 9) | @Test method hasSingleEggSingleFloor (line 14) | @Test method hasSingleEggMultipleFloor (line 19) | @Test method hasMultipleEggMultipleFloor (line 24) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/FibonacciTest.java class FibonacciTest (line 9) | public class FibonacciTest { method setUp (line 11) | @BeforeEach method testFibMemo (line 17) | @Test method testFibBotUp (line 33) | @Test method testFibOptimized (line 49) | @Test method testFibBinet (line 65) | @Test method testNegativeInput (line 81) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/KadaneAlgorithmTest.java class KadaneAlgorithmTest (line 8) | public class KadaneAlgorithmTest { method testMaxSumWithPositiveValues (line 10) | @Test method testMaxSumWithMixedValues (line 18) | @Test method testMaxSumWithAllNegativeValues (line 26) | @Test method testMaxSumWithSingleElement (line 34) | @Test method testMaxSumWithZero (line 47) | @Test method testMaxSumWithEmptyArray (line 55) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/KnapsackMemoizationTest.java class KnapsackMemoizationTest (line 7) | public class KnapsackMemoizationTest { method test1 (line 11) | @Test method test2 (line 19) | @Test method test3 (line 27) | @Test method test4 (line 35) | @Test method test5 (line 42) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/KnapsackTest.java class KnapsackTest (line 8) | public class KnapsackTest { method testKnapSackBasic (line 9) | @Test method testKnapSackEmpty (line 19) | @Test method testKnapSackNoCapacity (line 29) | @Test method testKnapSackMaxCapacity (line 39) | @Test method testKnapSackThrowsForInputsOfDifferentLength (line 49) | @Test method testKnapSackThrowsForNullInputs (line 57) | @Test method testKnapSackThrowsForNegativeCapacity (line 66) | @Test method testKnapSackThrowsForNegativeWeight (line 74) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/KnapsackZeroOneTabulationTest.java class KnapsackZeroOneTabulationTest (line 8) | public class KnapsackZeroOneTabulationTest { method basicCheck (line 10) | @Test method emptyKnapsack (line 22) | @Test method zeroCapacity (line 32) | @Test method negativeCapacity (line 42) | @Test method mismatchedLengths (line 53) | @Test method nullInputs (line 64) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/KnapsackZeroOneTest.java class KnapsackZeroOneTest (line 8) | class KnapsackZeroOneTest { method basicCheck (line 10) | @Test method zeroCapacity (line 21) | @Test method zeroItems (line 31) | @Test method weightsExceedingCapacity (line 41) | @Test method throwsOnNullArrays (line 51) | @Test method throwsOnMismatchedArrayLengths (line 57) | @Test method throwsOnNegativeInputs (line 62) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/LevenshteinDistanceTests.java class LevenshteinDistanceTests (line 13) | public class LevenshteinDistanceTests { method testLevenshteinDistance (line 15) | @ParameterizedTest method testCases (line 24) | private static Stream testCases() { FILE: src/test/java/com/thealgorithms/dynamicprogramming/LongestAlternatingSubsequenceTest.java class LongestAlternatingSubsequenceTest (line 10) | public class LongestAlternatingSubsequenceTest { method testAlternatingLength (line 12) | @ParameterizedTest method provideTestCases (line 18) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/dynamicprogramming/LongestArithmeticSubsequenceTest.java class LongestArithmeticSubsequenceTest (line 13) | public class LongestArithmeticSubsequenceTest { method testGetLongestArithmeticSubsequenceLength (line 14) | @ParameterizedTest method testGetLongestArithmeticSubsequenceLengthReversedInput (line 19) | @ParameterizedTest method testGetLongestArithmeticSubsequenceLengthThrowsForNullInput (line 26) | @Test method provideTestCases (line 31) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/dynamicprogramming/LongestCommonSubsequenceTest.java class LongestCommonSubsequenceTest (line 8) | public class LongestCommonSubsequenceTest { method testLCSBasic (line 10) | @Test method testLCSIdenticalStrings (line 19) | @Test method testLCSNoCommonCharacters (line 28) | @Test method testLCSWithEmptyString (line 37) | @Test method testLCSWithBothEmptyStrings (line 46) | @Test method testLCSWithNullFirstString (line 55) | @Test method testLCSWithNullSecondString (line 63) | @Test method testLCSWithNullBothStrings (line 71) | @Test method testLCSWithLongerStringContainingCommonSubsequence (line 79) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/LongestIncreasingSubsequenceNLogNTest.java class LongestIncreasingSubsequenceNLogNTest (line 10) | public class LongestIncreasingSubsequenceNLogNTest { method provideTestCases (line 12) | private static Stream provideTestCases() { method testLengthOfLIS (line 17) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/dynamicprogramming/LongestIncreasingSubsequenceTests.java class LongestIncreasingSubsequenceTests (line 12) | public class LongestIncreasingSubsequenceTests { type IntArrayToInt (line 13) | @FunctionalInterface method apply (line 15) | int apply(int[] array); method testLongestIncreasingSubsequence (line 18) | @ParameterizedTest method testCases (line 24) | private static Stream testCases() { FILE: src/test/java/com/thealgorithms/dynamicprogramming/LongestPalindromicSubstringTest.java class LongestPalindromicSubstringTest (line 10) | public class LongestPalindromicSubstringTest { method provideTestCases (line 12) | private static Stream provideTestCases() { method testLps (line 17) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/dynamicprogramming/LongestValidParenthesesTest.java class LongestValidParenthesesTest (line 10) | public class LongestValidParenthesesTest { method provideTestCases (line 12) | private static Stream provideTestCases() { method testLongestValidParentheses (line 17) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/dynamicprogramming/MatrixChainMultiplicationTest.java class MatrixChainMultiplicationTest (line 8) | class MatrixChainMultiplicationTest { method testMatrixCreation (line 10) | @Test method testMatrixChainOrder (line 24) | @Test method testOptimalParentheses (line 41) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/MatrixChainRecursiveTopDownMemoisationTest.java class MatrixChainRecursiveTopDownMemoisationTest (line 7) | class MatrixChainRecursiveTopDownMemoisationTest { method testFourMatrices (line 13) | @Test method testThreeMatrices (line 25) | @Test method testTwoMatrices (line 37) | @Test method testSingleMatrix (line 49) | @Test method testVaryingDimensions (line 61) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/MaximumProductSubarrayTest.java class MaximumProductSubarrayTest (line 7) | class MaximumProductSubarrayTest { method testAllPositiveNumbers (line 13) | @Test method testMixedPositiveAndNegative (line 25) | @Test method testArrayWithZeros (line 37) | @Test method testSingleElement (line 49) | @Test method testAllNegativeNumbers (line 61) | @Test method testOddNegativeNumbers (line 73) | @Test method testEmptyArray (line 85) | @Test method testNullArray (line 97) | @Test method testAlternatingNumbers (line 109) | @Test method testLargeNumbers (line 121) | @Test method testSingleNegativeElement (line 133) | @Test method testMultipleZeros (line 145) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/MaximumSumOfNonAdjacentElementsTest.java class MaximumSumOfNonAdjacentElementsTest (line 7) | public class MaximumSumOfNonAdjacentElementsTest { method testGetMaxSumApproach1WithEmptyArray (line 10) | @Test method testGetMaxSumApproach1WithSingleElement (line 15) | @Test method testGetMaxSumApproach1WithTwoElementsTakeMax (line 20) | @Test method testGetMaxSumApproach1WithMultipleElements (line 25) | @Test method testGetMaxSumApproach2WithEmptyArray (line 32) | @Test method testGetMaxSumApproach2WithSingleElement (line 37) | @Test method testGetMaxSumApproach2WithTwoElementsTakeMax (line 42) | @Test method testGetMaxSumApproach2WithMultipleElements (line 47) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/MinimumPathSumTest.java class MinimumPathSumTest (line 7) | public class MinimumPathSumTest { method testMinimumPathSumWithRegularGrid (line 9) | @Test method testMinimumPathSumWithOneRowOneColumnGrid (line 15) | @Test method testMinimumPathSumWithEmptyGrid (line 21) | @Test method testMinimumPathSumWithOneColumnGrid (line 27) | @Test method testMinimumPathSumGridOneRowGrid (line 33) | @Test method testMinimumPathSumWithDiffRowAndColumnGrid (line 39) | @Test method testMinimumPathSumWithNegativeNumberGrid (line 45) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/MinimumSumPartitionTest.java class MinimumSumPartitionTest (line 8) | class MinimumSumPartitionTest { method testMinimumSumPartitionWithEvenSum (line 9) | @Test method testMinimumSumPartitionWithOddSum (line 15) | @Test method testMinimumSumPartitionWithSingleElement (line 21) | @Test method testMinimumSumPartitionWithLargeNumbers (line 27) | @Test method testMinimumSumPartitionWithEmptyArray (line 33) | @Test method testMinimumSumPartitionThrowsForNegativeArray (line 39) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/NeedlemanWunschTest.java class NeedlemanWunschTest (line 13) | class NeedlemanWunschTest { method testIdenticalStrings (line 15) | @Test method testSimpleMismatch (line 21) | @Test method testInsertion (line 27) | @Test method testEmptyStrings (line 34) | @Test method testOneEmpty (line 39) | @Test method testGapHeavyAlignment (line 44) | @Test method testNullInputs (line 50) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/dynamicprogramming/NewManShanksPrimeTest.java class NewManShanksPrimeTest (line 13) | class NewManShanksPrimeTest { method testNthManShanksPrime1 (line 19) | @Test method testNthManShanksPrime2 (line 30) | @Test method testNthManShanksPrime3 (line 41) | @Test method testNthManShanksPrime4 (line 52) | @Test method testNthManShanksPrime5 (line 63) | @Test method testNthManShanksPrimeIncorrectAnswer (line 74) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/OptimalJobSchedulingTest.java class OptimalJobSchedulingTest (line 10) | public class OptimalJobSchedulingTest { method testOptimalJobScheduling1 (line 12) | @Test method testOptimalJobScheduling2 (line 37) | @Test method testOptimalJobScheduling3 (line 62) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/PalindromicPartitioningTest.java class PalindromicPartitioningTest (line 10) | public class PalindromicPartitioningTest { method provideTestCases (line 12) | private static Stream provideTestCases() { method testMinimalPartitions (line 16) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/dynamicprogramming/PartitionProblemTest.java class PartitionProblemTest (line 8) | class PartitionProblemTest { method testIfSumOfTheArrayIsOdd (line 9) | @Test method testIfSizeOfTheArrayIsOne (line 13) | @Test method testIfSumOfTheArrayIsEven1 (line 17) | @Test method testIfSumOfTheArrayIsEven2 (line 21) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/RegexMatchingTest.java class RegexMatchingTest (line 10) | public class RegexMatchingTest { method provideTestCases (line 15) | private static Stream provideTestCases() { method testRegexRecursionMethod1 (line 20) | @ParameterizedTest method testRegexRecursionMethod2 (line 26) | @ParameterizedTest method testRegexRecursionMethod3 (line 32) | @ParameterizedTest method testRegexBottomUp (line 38) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/dynamicprogramming/RodCuttingTest.java class RodCuttingTest (line 12) | class RodCuttingTest { method testCutRodLength1 (line 18) | @Test method testCutRodLength2 (line 30) | @Test method testCutRodLength3 (line 42) | @Test method testCutRodLength4 (line 54) | @Test method testCutRodLength5 (line 66) | @Test method testCutRodLength0 (line 78) | @Test method testCutRodEmptyPrices (line 90) | @Test method testCutRodNegativeLength (line 96) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/ShortestCommonSupersequenceLengthTest.java class ShortestCommonSupersequenceLengthTest (line 8) | public class ShortestCommonSupersequenceLengthTest { method testShortestSupersequence (line 9) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/dynamicprogramming/SmithWatermanTest.java class SmithWatermanTest (line 13) | class SmithWatermanTest { method testIdenticalStrings (line 15) | @Test method testPartialMatch (line 21) | @Test method testNoMatch (line 27) | @Test method testInsertionDeletion (line 33) | @Test method testEmptyStrings (line 39) | @Test method testNullInputs (line 44) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/dynamicprogramming/SubsetCountTest.java class SubsetCountTest (line 7) | public class SubsetCountTest { method hasMultipleSubset (line 8) | @Test method singleElementSubset (line 13) | @Test method hasMultipleSubsetSO (line 19) | @Test method singleSubsetSO (line 24) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/SubsetSumSpaceOptimizedTest.java class SubsetSumSpaceOptimizedTest (line 8) | public class SubsetSumSpaceOptimizedTest { method basicCheck (line 10) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/SubsetSumTest.java class SubsetSumTest (line 9) | class SubsetSumTest { method testSubsetSum (line 14) | @ParameterizedTest method provideTestCases (line 20) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/dynamicprogramming/SumOfSubsetTest.java class SumOfSubsetTest (line 8) | class SumOfSubsetTest { method basicCheck (line 10) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/TreeMatchingTest.java class TreeMatchingTest (line 9) | class TreeMatchingTest { method setUp (line 12) | @BeforeEach method testMaxMatchingForGeneralTree (line 20) | @Test method testMaxMatchingForBalancedTree (line 36) | @Test method testMaxMatchingForTreeWithVariedEdgeWeights (line 54) | @Test method emptyTree (line 72) | @Test method testSingleNodeTree (line 78) | @Test method testLinearTree (line 87) | @Test method testStarShapedTree (line 98) | @Test method testUnbalancedTree (line 109) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/TribonacciTest.java class TribonacciTest (line 10) | public class TribonacciTest { method testKnownValues (line 15) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/UniquePathsTests.java class UniquePathsTests (line 8) | public class UniquePathsTests { method testUniquePaths3x3 (line 10) | @Test method testUniquePaths1x1 (line 15) | @Test method testUniquePaths3x7 (line 20) | @Test method testUniquePaths7x3 (line 25) | @Test method testUniquePaths100x100 (line 30) | @Test method testUniquePathsII3x3 (line 35) | @Test method testUniquePathsII1x1 (line 40) | @Test method testUniquePathsII3x7 (line 45) | @Test method testUniquePathsII7x3 (line 50) | @Test method testUniquePathsII100x100 (line 55) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/UniqueSubsequencesCountTest.java class UniqueSubsequencesCountTest (line 8) | public class UniqueSubsequencesCountTest { method subseqCountParameterizedTest (line 10) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/dynamicprogramming/WildcardMatchingTest.java class WildcardMatchingTest (line 7) | public class WildcardMatchingTest { method testMatchingPattern (line 9) | @Test method testNonMatchingPattern (line 15) | @Test method testEmptyPattern (line 22) | @Test FILE: src/test/java/com/thealgorithms/dynamicprogramming/WineProblemTest.java class WineProblemTest (line 12) | class WineProblemTest { method testWpRecursion (line 17) | @Test method testWptd (line 27) | @Test method testWpbu (line 37) | @Test method testSingleWine (line 47) | @Test method testSamePriceWines (line 57) | @Test method testNoWines (line 67) | @Test FILE: src/test/java/com/thealgorithms/geometry/BentleyOttmannTest.java class BentleyOttmannTest (line 19) | public class BentleyOttmannTest { method testSingleIntersection (line 23) | @Test method testVerticalIntersection (line 32) | @Test method testNoIntersection (line 41) | @Test method testCoincidentSegments (line 49) | @Test method testHorizontalIntersection (line 60) | @Test method testEmptyList (line 68) | @Test method testSingleSegment (line 75) | @Test method testNullListThrowsException (line 82) | @Test method testParallelSegments (line 87) | @Test method testTouchingEndpoints (line 102) | @Test method testOverlappingCollinearSegments (line 111) | @Test method testMultipleSegmentsAtOnePoint (line 122) | @Test method testGridPattern (line 137) | @Test method testTriangleIntersections (line 166) | @Test method testCrossingDiagonals (line 182) | @Test method testVerySmallSegments (line 192) | @Test method testSegmentsShareCommonPoint (line 201) | @Test method testSegmentsAtAngles (line 213) | @Test method testPerformanceWithManySegments (line 226) | @Test method testIssueExample (line 254) | @Test method testEventTypeOrdering (line 269) | @Test method testCollinearOverlapWithInteriorPoint (line 282) | @Test method testCollinearTouchingAtBothEndpoints (line 293) | @Test method testCollinearOverlapPartialInterior (line 304) | @Test method newSegment (line 317) | private static BentleyOttmann.Segment newSegment(double x1, double y1,... method containsPoint (line 321) | private static boolean containsPoint(Set points, doubl... FILE: src/test/java/com/thealgorithms/geometry/BresenhamLineTest.java class BresenhamLineTest (line 20) | class BresenhamLineTest { method linePointsProvider (line 31) | static Stream linePointsProvider() { method testFindLine (line 50) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/geometry/ConvexHullTest.java class ConvexHullTest (line 11) | public class ConvexHullTest { method testConvexHullBruteForce (line 13) | @Test method testConvexHullRecursive (line 31) | @Test method testConvexHullRecursiveAdditionalCases (line 57) | @Test method isCounterClockwise (line 87) | private boolean isCounterClockwise(List points) { method testRecursiveHullForCoverage (line 102) | @Test FILE: src/test/java/com/thealgorithms/geometry/DDALineTest.java class DDALineTest (line 15) | class DDALineTest { method linePointsProvider (line 17) | static Stream linePointsProvider() { method testFindLine (line 23) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/geometry/GrahamScanTest.java class GrahamScanTest (line 7) | public class GrahamScanTest { method testGrahamScan (line 8) | @Test FILE: src/test/java/com/thealgorithms/geometry/HaversineTest.java class HaversineTest (line 16) | final class HaversineTest { method haversineTestProvider (line 28) | static Stream haversineTestProvider() { method testHaversine (line 53) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/geometry/MidpointCircleTest.java class MidpointCircleTest (line 13) | class MidpointCircleTest { method testGenerateCirclePoints (line 23) | @ParameterizedTest method testZeroRadiusCircle (line 48) | @Test FILE: src/test/java/com/thealgorithms/geometry/MidpointEllipseTest.java class MidpointEllipseTest (line 21) | class MidpointEllipseTest { method ellipseTestProvider (line 29) | static Stream ellipseTestProvider() { method testDrawEllipse (line 86) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/geometry/PointTest.java class PointTest (line 9) | public class PointTest { method testCompareTo (line 11) | @Test method testToString (line 22) | @Test method testPolarOrder (line 28) | @Test method testOrientation (line 34) | @Test method testPolarOrderCompare (line 63) | @Test FILE: src/test/java/com/thealgorithms/geometry/WusLineTest.java class WusLineTest (line 13) | class WusLineTest { method testSimpleLineProducesPixels (line 15) | @Test method testEndpointsIncluded (line 21) | @Test method testIntensityInRange (line 30) | @Test method testReversedEndpointsProducesSameLine (line 38) | @Test method testSteepLineHasProperCoverage (line 50) | @Test method testZeroLengthLineUsesDefaultGradient (line 65) | @Test method testHorizontalLineIntensityStable (line 75) | @Test FILE: src/test/java/com/thealgorithms/graph/BronKerboschTest.java class BronKerboschTest (line 13) | class BronKerboschTest { method completeGraph (line 15) | @Test method pathGraph (line 31) | @Test method disconnectedGraph (line 44) | @Test method nullNeighborSet (line 59) | @Test method buildGraph (line 67) | private static List> buildGraph(int n) { method addUndirectedEdge (line 75) | private static void addUndirectedEdge(List> graph, int u,... FILE: src/test/java/com/thealgorithms/graph/ConstrainedShortestPathTest.java class ConstrainedShortestPathTest (line 8) | public class ConstrainedShortestPathTest { method testSimpleGraph (line 14) | @Test method testNoPath (line 30) | @Test method testMultiplePaths (line 46) | @Test method testExactResourceLimit (line 64) | @Test method testDisconnectedGraph (line 80) | @Test method testGraphWithCycles (line 96) | @Test method testLargeGraphPerformance (line 114) | @Test method testIsolatedNodes (line 132) | @Test method testCyclicLargeGraph (line 148) | @Test method testLargeComplexGraph (line 166) | @Test method testSingleNodeGraph (line 192) | @Test method testTightResourceConstraint (line 206) | @Test FILE: src/test/java/com/thealgorithms/graph/DinicTest.java class DinicTest (line 9) | class DinicTest { method clrsExample (line 10) | @Test method disconnectedGraph (line 18) | @Test method sourceEqualsSink (line 26) | @Test method invalidMatrix (line 34) | @Test method parityWithEdmondsKarp (line 41) | @Test method copyMatrix (line 64) | private static int[][] copyMatrix(int[][] a) { FILE: src/test/java/com/thealgorithms/graph/EdmondsKarpTest.java class EdmondsKarpTest (line 9) | class EdmondsKarpTest { method clrsExample (line 11) | @Test method disconnectedGraph (line 19) | @Test method sourceEqualsSink (line 27) | @Test method invalidMatrix (line 35) | @Test method negativeCapacity (line 42) | @Test FILE: src/test/java/com/thealgorithms/graph/EdmondsTest.java class EdmondsTest (line 10) | class EdmondsTest { method testSimpleGraphNoCycle (line 12) | @Test method testGraphWithOneCycle (line 28) | @Test method testComplexGraphWithCycle (line 49) | @Test method testUnreachableNode (line 77) | @Test method testNoEdgesToNonRootNodes (line 89) | @Test method testSingleNode (line 100) | @Test method testInvalidInputThrowsException (line 110) | @Test method testCoverageForEdgeSelectionLogic (line 119) | @Test method testCoverageForContractedSelfLoop (line 140) | @Test FILE: src/test/java/com/thealgorithms/graph/GomoryHuTreeTest.java class GomoryHuTreeTest (line 15) | class GomoryHuTreeTest { method singleNode (line 17) | @Test method triangleGraph (line 28) | @Test method randomSmallGraphs (line 45) | @Test method randSymmetricMatrix (line 58) | private static int[][] randSymmetricMatrix(int n, int lo, int hi, Rand... method validateAllPairs (line 74) | private static void validateAllPairs(int[][] cap, int[][] tree) { method minEdgeOnPath (line 100) | private static int minEdgeOnPath(List> g, int s, int t) { FILE: src/test/java/com/thealgorithms/graph/HierholzerAlgorithmTest.java class HierholzerAlgorithmTest (line 15) | public class HierholzerAlgorithmTest { method testFindsEulerianCircuitInSimpleTriangleGraph (line 17) | @Test method testFailsForGraphWithOddDegreeVertices (line 30) | @Test method testFailsForDisconnectedGraph (line 40) | @Test method testHandlesEmptyGraph (line 53) | @Test FILE: src/test/java/com/thealgorithms/graph/HierholzerEulerianPathTest.java class HierholzerEulerianPathTest (line 28) | class HierholzerEulerianPathTest { method testSimpleEulerianCircuit (line 30) | @Test method testEulerianPathDifferentStartEnd (line 45) | @Test method testNoEulerianPathExists (line 61) | @Test method testDisconnectedGraph (line 74) | @Test method testGraphWithSelfLoop (line 87) | @Test method testSingleNodeNoEdges (line 102) | @Test method testSingleNodeWithLoop (line 113) | @Test method testComplexEulerianCircuit (line 125) | @Test method testMultipleEdgesBetweenSameNodes (line 145) | @Test method testCoverageForEmptyGraph (line 160) | @Test FILE: src/test/java/com/thealgorithms/graph/HopcroftKarpTest.java class HopcroftKarpTest (line 17) | class HopcroftKarpTest { method adj (line 19) | private static List> adj(int nLeft) { method emptyGraph (line 27) | @Test method singleEdge (line 35) | @Test method disjointEdges (line 49) | @Test method completeK34 (line 69) | @Test method rectangularSparse (line 93) | @Test method layeringAdvantage (line 120) | @Test FILE: src/test/java/com/thealgorithms/graph/HungarianAlgorithmTest.java class HungarianAlgorithmTest (line 9) | class HungarianAlgorithmTest { method classicSquareExample (line 11) | @Test method rectangularMoreRows (line 20) | @Test method zeroDiagonal (line 37) | @Test FILE: src/test/java/com/thealgorithms/graph/PredecessorConstrainedDfsTest.java class PredecessorConstrainedDfsTest (line 13) | class PredecessorConstrainedDfsTest { method diamond (line 16) | private static Map> diamond() { method dfsRecursiveOrderEmitsSkipUntilAllParentsVisited (line 25) | @Test method returnsEmptyWhenStartNotInGraph (line 50) | @Test method nullSuccessorsThrows (line 56) | @Test method worksWithExplicitPredecessors (line 61) | @Test method cycleProducesSkipsButNoInfiniteRecursion (line 78) | @Test FILE: src/test/java/com/thealgorithms/graph/PushRelabelTest.java class PushRelabelTest (line 8) | class PushRelabelTest { method clrsExample (line 10) | @Test method disconnectedGraph (line 18) | @Test method sourceEqualsSink (line 26) | @Test method parityWithOtherMaxFlow (line 34) | @Test method copyMatrix (line 59) | private static int[][] copyMatrix(int[][] a) { FILE: src/test/java/com/thealgorithms/graph/StoerWagnerTest.java class StoerWagnerTest (line 14) | public class StoerWagnerTest { method testSimpleGraph (line 16) | @Test method testTriangleGraph (line 23) | @Test method testDisconnectedGraph (line 30) | @Test method testCompleteGraph (line 37) | @Test method testSingleVertex (line 44) | @Test method testTwoVertices (line 51) | @Test method testSquareGraphWithDiagonal (line 58) | @Test FILE: src/test/java/com/thealgorithms/graph/StronglyConnectedComponentOptimizedTest.java class StronglyConnectedComponentOptimizedTest (line 11) | public class StronglyConnectedComponentOptimizedTest { method setUp (line 15) | @BeforeEach method testSingleComponent (line 20) | @Test method testTwoComponents (line 34) | @Test method testDisconnectedGraph (line 49) | @Test method testComplexGraph (line 64) | @Test FILE: src/test/java/com/thealgorithms/graph/TravelingSalesmanTest.java class TravelingSalesmanTest (line 7) | public class TravelingSalesmanTest { method testBruteForceSimple (line 10) | @Test method testDynamicProgrammingSimple (line 18) | @Test method testBruteForceThreeCities (line 27) | @Test method testDynamicProgrammingThreeCities (line 35) | @Test method testBruteForceFiveCities (line 44) | @Test method testDynamicProgrammingFiveCities (line 52) | @Test method testBruteForceTwoCities (line 61) | @Test method testDynamicProgrammingTwoCities (line 69) | @Test method testBruteForceEqualDistances (line 78) | @Test method testDynamicProgrammingEqualDistances (line 86) | @Test method testBruteForceOneCity (line 95) | @Test method testDynamicProgrammingOneCity (line 103) | @Test method testBruteForceLargeNumbers (line 112) | @Test method testDynamicProgrammingLargeNumbers (line 120) | @Test FILE: src/test/java/com/thealgorithms/graph/YensKShortestPathsTest.java class YensKShortestPathsTest (line 10) | class YensKShortestPathsTest { method basicKPaths (line 12) | @Test method kLargerThanAvailable (line 42) | @Test method noPath (line 52) | @Test method sourceEqualsDestination (line 60) | @Test method negativeWeightsRejected (line 70) | @Test FILE: src/test/java/com/thealgorithms/graph/ZeroOneBfsTest.java class ZeroOneBfsTest (line 10) | class ZeroOneBfsTest { method makeAdj (line 13) | private static List> makeAdj(int n) { method simpleLineGraph (line 21) | @Test method parallelEdgesPreferZero (line 34) | @Test method unreachableNodes (line 47) | @Test method invalidArgs (line 57) | @Test FILE: src/test/java/com/thealgorithms/greedyalgorithms/ActivitySelectionTest.java class ActivitySelectionTest (line 11) | public class ActivitySelectionTest { method testActivitySelection (line 12) | @Test method testSingleActivity (line 23) | @Test method testNoOverlap (line 34) | @Test FILE: src/test/java/com/thealgorithms/greedyalgorithms/BandwidthAllocationTest.java class BandwidthAllocationTest (line 10) | public class BandwidthAllocationTest { method testMaxValue (line 12) | @ParameterizedTest method bandwidthProvider (line 18) | private static Stream bandwidthProvider() { FILE: src/test/java/com/thealgorithms/greedyalgorithms/BinaryAdditionTest.java class BinaryAdditionTest (line 7) | public class BinaryAdditionTest { method testEqualLengthNoCarry (line 11) | @Test method testEqualLengthWithCarry (line 19) | @Test method testDifferentLengths (line 27) | @Test method testAllZeros (line 35) | @Test method testAllOnes (line 43) | @Test method testOneZeroString (line 51) | @Test method testLargeBinaryNumbers (line 65) | @Test method testOneMuchLonger (line 73) | @Test method testEmptyStrings (line 81) | @Test method testAlternatingBits (line 89) | @Test FILE: src/test/java/com/thealgorithms/greedyalgorithms/CoinChangeTest.java class CoinChangeTest (line 11) | public class CoinChangeTest { method testCoinChangeProblemWithValidAmount (line 12) | @Test method testCoinChangeProblemWithLargeAmount (line 19) | @Test method testCoinChangeProblemWithPartialCoins2 (line 26) | @Test method testCoinChangeProblemWithSmallAmount (line 33) | @Test method testCoinChangeProblemWithLargeAmountAndMultipleDenominations (line 40) | @Test method testCoinChangeProblemWithAllDenominations (line 47) | @Test method testCoinChangeProblemWithZeroAmount (line 54) | @Test FILE: src/test/java/com/thealgorithms/greedyalgorithms/DigitSeparationTest.java class DigitSeparationTest (line 7) | public class DigitSeparationTest { method testDigitSeparationReverseOrderSingleDigit (line 9) | @Test method testDigitSeparationReverseOrderMultipleDigits (line 16) | @Test method testDigitSeparationReverseOrderLargeNumber (line 23) | @Test method testDigitSeparationReverseOrderZero (line 30) | @Test method testDigitSeparationReverseOrderNegativeNumbers (line 37) | @Test method testDigitSeparationForwardOrderSingleDigit (line 44) | @Test method testDigitSeparationForwardOrderMultipleDigits (line 51) | @Test method testDigitSeparationForwardOrderLargeNumber (line 58) | @Test method testDigitSeparationForwardOrderZero (line 65) | @Test method testDigitSeparationForwardOrderNegativeNumber (line 72) | @Test FILE: src/test/java/com/thealgorithms/greedyalgorithms/EgyptianFractionTest.java class EgyptianFractionTest (line 11) | public class EgyptianFractionTest { method testGetEgyptianFraction (line 13) | @ParameterizedTest method fractionProvider (line 19) | private static Stream fractionProvider() { FILE: src/test/java/com/thealgorithms/greedyalgorithms/FractionalKnapsackTest.java class FractionalKnapsackTest (line 7) | public class FractionalKnapsackTest { method testFractionalKnapsackWithExampleCase (line 9) | @Test method testFractionalKnapsackWithZeroCapacity (line 17) | @Test method testFractionalKnapsackWithEmptyItems (line 25) | @Test FILE: src/test/java/com/thealgorithms/greedyalgorithms/GaleShapleyTest.java class GaleShapleyTest (line 11) | public class GaleShapleyTest { method testStableMatch (line 13) | @Test method testSinglePair (line 35) | @Test method testEqualPreferences (line 51) | @Test FILE: src/test/java/com/thealgorithms/greedyalgorithms/JobSequencingTest.java class JobSequencingTest (line 9) | public class JobSequencingTest { method testJobSequencingWithExampleCase (line 10) | @Test FILE: src/test/java/com/thealgorithms/greedyalgorithms/KCentersTest.java class KCentersTest (line 7) | public class KCentersTest { method testFindKCenters (line 9) | @Test FILE: src/test/java/com/thealgorithms/greedyalgorithms/MergeIntervalsTest.java class MergeIntervalsTest (line 7) | public class MergeIntervalsTest { method testMergeIntervalsWithOverlappingIntervals (line 9) | @Test method testMergeIntervalsWithNoOverlap (line 18) | @Test method testMergeIntervalsWithCompleteOverlap (line 27) | @Test method testMergeIntervalsWithSingleInterval (line 36) | @Test method testMergeIntervalsWithEmptyArray (line 45) | @Test method testMergeIntervalsWithIdenticalIntervals (line 54) | @Test method testMergeIntervalsWithRandomIntervals (line 63) | @Test FILE: src/test/java/com/thealgorithms/greedyalgorithms/MinimizingLatenessTest.java class MinimizingLatenessTest (line 8) | public class MinimizingLatenessTest { method testCalculateLateness (line 10) | @Test method testCheckStartTime (line 28) | @Test FILE: src/test/java/com/thealgorithms/greedyalgorithms/MinimumWaitingTimeTest.java class MinimumWaitingTimeTest (line 10) | public class MinimumWaitingTimeTest { method testMinimumWaitingTime (line 12) | @ParameterizedTest method provideTestCases (line 18) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/greedyalgorithms/OptimalFileMergingTest.java class OptimalFileMergingTest (line 10) | public class OptimalFileMergingTest { method testMinMergeCost (line 12) | @ParameterizedTest method fileMergingProvider (line 18) | private static Stream fileMergingProvider() { FILE: src/test/java/com/thealgorithms/greedyalgorithms/StockProfitCalculatorTest.java class StockProfitCalculatorTest (line 10) | public class StockProfitCalculatorTest { method testMaxProfit (line 12) | @ParameterizedTest method provideTestCases (line 18) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/io/BufferedReaderTest.java class BufferedReaderTest (line 9) | class BufferedReaderTest { method testPeeks (line 10) | @Test method testMixes (line 31) | @Test method testBlockPractical (line 68) | @Test FILE: src/test/java/com/thealgorithms/lineclipping/CohenSutherlandTest.java class CohenSutherlandTest (line 15) | class CohenSutherlandTest { method testLineCompletelyInside (line 20) | @Test method testLineCompletelyOutside (line 30) | @Test method testLinePartiallyInside (line 39) | @Test method testLineOnBoundary (line 50) | @Test method testDiagonalLineThroughClippingWindow (line 60) | @Test method testVerticalLineClipping (line 71) | @Test FILE: src/test/java/com/thealgorithms/lineclipping/LiangBarskyTest.java class LiangBarskyTest (line 15) | class LiangBarskyTest { method testLineCompletelyInside (line 19) | @Test method testLineCompletelyOutside (line 28) | @Test method testLinePartiallyInside (line 36) | @Test method testDiagonalLineThroughClippingWindow (line 46) | @Test method testVerticalLineClipping (line 56) | @Test FILE: src/test/java/com/thealgorithms/maths/ADTFractionTest.java class ADTFractionTest (line 9) | public class ADTFractionTest { method testConstructorWithDenominatorEqualToZero (line 14) | @Test method testPlus (line 20) | @Test method testTimes (line 25) | @Test method testReciprocal (line 31) | @Test method testValue (line 36) | @Test method testEqualsAndHashCode (line 41) | @Test method testToString (line 48) | @Test FILE: src/test/java/com/thealgorithms/maths/AbsoluteMaxTest.java class AbsoluteMaxTest (line 8) | public class AbsoluteMaxTest { method testGetMaxValue (line 10) | @Test method testGetMaxValueWithNoArguments (line 18) | @Test method testGetMaxValueWithSameAbsoluteValues (line 23) | @Test FILE: src/test/java/com/thealgorithms/maths/AbsoluteMinTest.java class AbsoluteMinTest (line 8) | public class AbsoluteMinTest { method testGetMinValue (line 10) | @Test method testGetMinValueWithNoArguments (line 16) | @Test method testGetMinValueWithSameAbsoluteValues (line 22) | @Test FILE: src/test/java/com/thealgorithms/maths/AbsoluteValueTest.java class AbsoluteValueTest (line 9) | public class AbsoluteValueTest { method testGetAbsValue (line 11) | @Test method testZero (line 16) | @Test method testPositiveNumbers (line 21) | @Test method testNegativeNumbers (line 28) | @Test method testMinIntEdgeCase (line 35) | @Test FILE: src/test/java/com/thealgorithms/maths/AbundantNumberTest.java class AbundantNumberTest (line 10) | class AbundantNumberTest { method abundantNumbersTest (line 11) | @ParameterizedTest method nonAbundantNumbersTest (line 18) | @ParameterizedTest method throwsNegativeNumbersNotAllowed (line 25) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/maths/AliquotSumTest.java class AliquotSumTest (line 7) | public class AliquotSumTest { method testGetMaxValue (line 9) | @Test FILE: src/test/java/com/thealgorithms/maths/AmicableNumberTest.java class AmicableNumberTest (line 10) | public class AmicableNumberTest { method testShouldThrowExceptionWhenInvalidRangeProvided (line 14) | @Test method testShouldThrowExceptionWhenInvalidNumbersProvided (line 23) | @Test method testAmicableNumbers (line 30) | @Test method testShouldFindAllAmicableNumbersInRange (line 37) | @Test method checkInvalidRange (line 49) | private static void checkInvalidRange(int from, int to) { method checkInvalidNumbers (line 54) | private static void checkInvalidNumbers(int a, int b) { FILE: src/test/java/com/thealgorithms/maths/AreaTest.java class AreaTest (line 12) | class AreaTest { method testSurfaceAreaCube (line 14) | @Test method testSurfaceAreaCuboid (line 19) | @Test method testSurfaceAreaSphere (line 24) | @Test method testSurfaceAreaRectangle (line 29) | @Test method testSurfaceAreaCylinder (line 34) | @Test method testSurfaceAreaSquare (line 39) | @Test method testSurfaceAreaTriangle (line 44) | @Test method testSurfaceAreaParallelogram (line 49) | @Test method testSurfaceAreaTrapezium (line 54) | @Test method testSurfaceAreaCircle (line 59) | @Test method surfaceAreaHemisphere (line 64) | @Test method surfaceAreaCone (line 69) | @Test method testAllIllegalInput (line 74) | @Test FILE: src/test/java/com/thealgorithms/maths/ArmstrongTest.java class ArmstrongTest (line 11) | class ArmstrongTest { method testIsArmstrong (line 13) | @Test FILE: src/test/java/com/thealgorithms/maths/AutoCorrelationTest.java class AutoCorrelationTest (line 15) | public class AutoCorrelationTest { method testAutoCorrelationParameterized (line 17) | @ParameterizedTest method convertStringToArray (line 29) | private double[] convertStringToArray(String input) { FILE: src/test/java/com/thealgorithms/maths/AutomorphicNumberTest.java class AutomorphicNumberTest (line 8) | public class AutomorphicNumberTest { method testAutomorphicNumber (line 10) | @Test FILE: src/test/java/com/thealgorithms/maths/AverageTest.java class AverageTest (line 12) | public class AverageTest { method testAverageDouble (line 16) | @ParameterizedTest(name = "average({0}) should be approximately {1}") method testAverageInt (line 22) | @ParameterizedTest(name = "average({0}) should be {1}") method testAverageDoubleThrowsExceptionOnNullOrEmpty (line 28) | @Test method testAverageIntThrowsExceptionOnNullOrEmpty (line 34) | @Test method provideDoubleArrays (line 40) | private static Stream provideDoubleArrays() { method provideIntArrays (line 45) | private static Stream provideIntArrays() { FILE: src/test/java/com/thealgorithms/maths/BellNumbersTest.java class BellNumbersTest (line 8) | class BellNumbersTest { method testStandardCases (line 10) | @Test method testMediumNumber (line 21) | @Test method testLargeNumber (line 29) | @Test method testMaxLongCapacity (line 36) | @Test method testNegativeInput (line 43) | @Test method testOverflowProtection (line 48) | @Test FILE: src/test/java/com/thealgorithms/maths/BinaryPowTest.java class BinaryPowTest (line 7) | public class BinaryPowTest { method testBinPow (line 9) | @Test method testZeroExponent (line 17) | @Test method testZeroBase (line 24) | @Test method testOneBase (line 30) | @Test method testNegativeBase (line 36) | @Test method testLargeExponent (line 42) | @Test FILE: src/test/java/com/thealgorithms/maths/BinomialCoefficientTest.java class BinomialCoefficientTest (line 7) | public class BinomialCoefficientTest { method testBinomialCoefficient (line 9) | @Test FILE: src/test/java/com/thealgorithms/maths/CatalanNumbersTest.java class CatalanNumbersTest (line 14) | class CatalanNumbersTest { method catalanNumbersProvider (line 21) | static Stream catalanNumbersProvider() { method testCatalanNumbers (line 29) | @ParameterizedTest method testIllegalInput (line 38) | @Test FILE: src/test/java/com/thealgorithms/maths/CeilTest.java class CeilTest (line 10) | public class CeilTest { method testCeil (line 12) | @ParameterizedTest method testEdgeCases (line 18) | @ParameterizedTest method edgeCaseProvider (line 27) | static Stream edgeCaseProvider() { FILE: src/test/java/com/thealgorithms/maths/ChebyshevIterationTest.java class ChebyshevIterationTest (line 8) | public class ChebyshevIterationTest { method testSolveSimple2x2Diagonal (line 10) | @Test method testSolve2x2Symmetric (line 25) | @Test method testAlreadyAtSolution (line 40) | @Test method testMismatchedDimensionsAB (line 55) | @Test method testMismatchedDimensionsAX (line 63) | @Test method testNonSquareMatrix (line 71) | @Test method testInvalidEigenvalues (line 79) | @Test method testNonPositiveDefinite (line 88) | @Test method testInvalidIterationCount (line 97) | @Test FILE: src/test/java/com/thealgorithms/maths/ChineseRemainderTheoremTest.java class ChineseRemainderTheoremTest (line 10) | public class ChineseRemainderTheoremTest { method testCRTSimpleCase (line 11) | @Test method testCRTLargeModuli (line 20) | @Test method testCRTWithSingleCongruence (line 29) | @Test method testCRTWithMultipleSolutions (line 38) | @Test method testCRTLargeNumbers (line 47) | @Test FILE: src/test/java/com/thealgorithms/maths/CollatzConjectureTest.java class CollatzConjectureTest (line 11) | class CollatzConjectureTest { method setUp (line 15) | @BeforeAll method nextNumberFromEvenNumber (line 20) | @Test method nextNumberFromOddNumber (line 25) | @Test method collatzConjecture (line 30) | @Test method sequenceOfNotNaturalFirstNumber (line 36) | @Test FILE: src/test/java/com/thealgorithms/maths/CombinationsTest.java class CombinationsTest (line 7) | public class CombinationsTest { method testCombination (line 9) | @Test method testCombinationOptimised (line 17) | @Test FILE: src/test/java/com/thealgorithms/maths/ComplexNumberMultiplyTest.java class ComplexNumberMultiplyTest (line 8) | public class ComplexNumberMultiplyTest { method testExample (line 10) | @Test method testNegative (line 15) | @Test method testZero (line 20) | @Test method testInvalidFormat (line 25) | @Test method testNullInput (line 30) | @Test FILE: src/test/java/com/thealgorithms/maths/ConvolutionFFTTest.java class ConvolutionFFTTest (line 12) | public class ConvolutionFFTTest { method createComplexSignal (line 17) | private ArrayList createComplexSignal(double[] values) { method assertComplexArrayEquals (line 28) | private void assertComplexArrayEquals(List expected, List... method testConvolutionFFT (line 38) | @ParameterizedTest(name = "Test case {index}: {3}") method provideTestCases (line 50) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/maths/ConvolutionTest.java class ConvolutionTest (line 9) | public class ConvolutionTest { method testConvolution (line 14) | @ParameterizedTest(name = "{0}") method provideTestCases (line 21) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/maths/CrossCorrelationTest.java class CrossCorrelationTest (line 14) | public class CrossCorrelationTest { method testCrossCorrelationParameterized (line 16) | @ParameterizedTest method convertStringToArray (line 29) | private double[] convertStringToArray(String input) { FILE: src/test/java/com/thealgorithms/maths/DeterminantOfMatrixTest.java class DeterminantOfMatrixTest (line 7) | public class DeterminantOfMatrixTest { method testDeterminant2x2Matrix (line 9) | @Test method testDeterminant3x3Matrix (line 16) | @Test method testDeterminant3x3MatrixNonZero (line 23) | @Test method testDeterminant1x1Matrix (line 30) | @Test method testDeterminant4x4Matrix (line 37) | @Test method testDeterminant4x4MatrixZero (line 44) | @Test FILE: src/test/java/com/thealgorithms/maths/DigitalRootTest.java class DigitalRootTest (line 7) | public class DigitalRootTest { method testDigitalroot (line 9) | @Test FILE: src/test/java/com/thealgorithms/maths/DistanceBetweenTwoPointsTest.java class DistanceBetweenTwoPointsTest (line 7) | class DistanceBetweenTwoPointsTest { method testDistanceSimple (line 9) | @Test method testDistanceNegativeCoordinates (line 14) | @Test method testSamePoint (line 19) | @Test FILE: src/test/java/com/thealgorithms/maths/DistanceFormulaTest.java class DistanceFormulaTest (line 8) | public class DistanceFormulaTest { method euclideanTest1 (line 10) | @Test method euclideanTest2 (line 15) | @Test method euclideanTest3 (line 20) | @Test method euclideanTest4 (line 25) | @Test method manhattantest1 (line 30) | @Test method manhattantest2 (line 35) | @Test method manhattanTest3 (line 40) | @Test method hammingTest1 (line 45) | @Test method hammingTest2 (line 52) | @Test method hammingTest3 (line 59) | @Test method minkowskiTest1 (line 66) | @Test method minkowskiTest2 (line 73) | @Test method minkowskiTest3 (line 80) | @Test FILE: src/test/java/com/thealgorithms/maths/DudeneyNumberTest.java class DudeneyNumberTest (line 10) | class DudeneyNumberTest { method positiveDudeneyBase10Power3 (line 11) | @ParameterizedTest method negativeDudeneyBase10Power3 (line 17) | @ParameterizedTest method throwsInputLessThanOne (line 23) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/maths/EulerMethodTest.java class EulerMethodTest (line 14) | class EulerMethodTest { class EulerFullTestCase (line 16) | private static class EulerFullTestCase { method EulerFullTestCase (line 23) | EulerFullTestCase(double[] params, BiFunction eulerStepTestCases() { method testEulerStepInvalidInput (line 43) | @ParameterizedTest method eulerStepInvalidCases (line 49) | static Stream eulerStepInvalidCases() { method testEulerFull (line 54) | @ParameterizedTest method eulerFullTestCases (line 63) | static Stream eulerFullTestCases() { method testEulerFullInvalidInput (line 69) | @ParameterizedTest method eulerFullInvalidCases (line 75) | static Stream eulerFullInvalidCases() { FILE: src/test/java/com/thealgorithms/maths/EulerPseudoprimeTest.java class EulerPseudoprimeTest (line 13) | class EulerPseudoprimeTest { method testPrimeNumbers (line 15) | @Test method testCompositeNumbers (line 22) | @Test method testEvenNumbers (line 29) | @Test method testEdgeCases (line 35) | @Test method testIsProbablePrimeWhenJacobiSymbolIsZero (line 43) | @Test method testJacobiSymbolThrowsForEvenOrNonPositiveN (line 56) | @Test FILE: src/test/java/com/thealgorithms/maths/EulersFunctionTest.java class EulersFunctionTest (line 11) | class EulersFunctionTest { method testGetEuler (line 13) | @ParameterizedTest method testGetEulerThrowsExceptionForNonPositiveInput (line 19) | @ParameterizedTest method provideNumbersForGetEuler (line 25) | private static Stream provideNumbersForGetEuler() { method provideInvalidNumbersForGetEuler (line 30) | private static Stream provideInvalidNumbersForGetEuler() { FILE: src/test/java/com/thealgorithms/maths/EvilNumberTest.java class EvilNumberTest (line 10) | class EvilNumberTest { method evilNumbersTest (line 11) | @ParameterizedTest method odiousNumbersTest (line 17) | @ParameterizedTest method throwsNegativeNumbersNotAllowed (line 23) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/maths/ExtendedEuclideanAlgorithmTest.java class ExtendedEuclideanAlgorithmTest (line 7) | public class ExtendedEuclideanAlgorithmTest { method verifyBezoutIdentity (line 13) | private void verifyBezoutIdentity(long a, long b, long[] result) { method testExtendedGCD (line 20) | @Test FILE: src/test/java/com/thealgorithms/maths/FFTTest.java class FFTTest (line 9) | class FFTTest { method getRealtest (line 12) | @Test method getImaginaryTest (line 19) | @Test method addTest (line 26) | @Test method addFalseTest (line 35) | @Test method subtractTest (line 44) | @Test method multiplyWithComplexTest (line 53) | @Test method multiplyWithScalarTest (line 64) | @Test method conjugateTest (line 75) | @Test method abs (line 85) | @Test method divideWithComplexTest (line 93) | @Test method divideWithScalarTest (line 104) | @Test method fft (line 116) | @Test FILE: src/test/java/com/thealgorithms/maths/FactorialTest.java class FactorialTest (line 8) | public class FactorialTest { method testWhenInvalidInoutProvidedShouldThrowException (line 11) | @Test method testCorrectFactorialCalculation (line 17) | @Test FILE: src/test/java/com/thealgorithms/maths/FastExponentiationTest.java class FastExponentiationTest (line 14) | class FastExponentiationTest { method testSmallNumbers (line 19) | @Test method testWithModulo (line 28) | @Test method testBaseCases (line 37) | @Test method testNegativeBase (line 47) | @Test method testNegativeExponent (line 55) | @Test method testInvalidModulus (line 63) | @Test FILE: src/test/java/com/thealgorithms/maths/FastInverseSqrtTests.java class FastInverseSqrtTests (line 7) | public class FastInverseSqrtTests { method testForOneElement (line 9) | @Test method testForsecond (line 15) | @Test method testForThird (line 21) | @Test method testForFourth (line 26) | @Test method testForFifth (line 31) | @Test method testForSixth (line 36) | @Test method testForSeventh (line 41) | @Test method testForEighth (line 46) | @Test FILE: src/test/java/com/thealgorithms/maths/FibonacciJavaStreamsTest.java class FibonacciJavaStreamsTest (line 11) | public class FibonacciJavaStreamsTest { method testWithNegativeIndexShouldThrowException (line 14) | @Test method testCheckTheFirst4SequenceElements (line 20) | @Test method testCheck10thSequenceElement (line 28) | @Test method testCheck20thSequenceElement (line 33) | @Test method testCheck30thSequenceElement (line 38) | @Test method testCheck40thSequenceElement (line 43) | @Test method testCheck50thSequenceElement (line 48) | @Test method testCheck100thSequenceElement (line 53) | @Test method testCheck200thSequenceElement (line 58) | @Test method checkElement (line 63) | private static void checkElement(BigDecimal index, BigDecimal expected) { FILE: src/test/java/com/thealgorithms/maths/FibonacciLoopTest.java class FibonacciLoopTest (line 9) | public class FibonacciLoopTest { method checkValueAtZero (line 10) | @Test method checkValueAtOne (line 15) | @Test method checkValueAtTwo (line 20) | @Test method checkRecurrenceRelation (line 25) | @Test method checkNegativeInput (line 32) | @Test FILE: src/test/java/com/thealgorithms/maths/FibonacciNumberCheckTest.java class FibonacciNumberCheckTest (line 11) | public class FibonacciNumberCheckTest { method testNumberIsFibonacciNumber (line 12) | @Test method testNumberIsNotFibonacciNumber (line 23) | @Test FILE: src/test/java/com/thealgorithms/maths/FibonacciNumberGoldenRationTest.java class FibonacciNumberGoldenRationTest (line 9) | public class FibonacciNumberGoldenRationTest { method returnsCorrectValues (line 11) | @Test method throwsIllegalArgumentExceptionForNegativeInput (line 20) | @Test method throwsIllegalArgumentExceptionForLargeInput (line 25) | @Test FILE: src/test/java/com/thealgorithms/maths/FindKthNumberTest.java class FindKthNumberTest (line 10) | public class FindKthNumberTest { method testFindKthMaxTypicalCases (line 11) | @Test method testFindKthMaxEdgeCases (line 30) | @Test method testFindKthMaxInvalidK (line 43) | @Test method testFindKthMaxLargeArray (line 52) | @Test method generateArray (line 63) | public static int[] generateArray(int capacity) { FILE: src/test/java/com/thealgorithms/maths/FindMaxRecursionTest.java class FindMaxRecursionTest (line 12) | public class FindMaxRecursionTest { method numberTests (line 14) | @ParameterizedTest method inputStream (line 20) | private static Stream inputStream() { method testFindMaxThrowsExceptionForEmptyInput (line 24) | @Test FILE: src/test/java/com/thealgorithms/maths/FindMaxTest.java class FindMaxTest (line 12) | public class FindMaxTest { method numberTests (line 14) | @ParameterizedTest method inputStream (line 20) | private static Stream inputStream() { method testFindMaxThrowsExceptionForEmptyInput (line 24) | @Test FILE: src/test/java/com/thealgorithms/maths/FindMinRecursionTest.java class FindMinRecursionTest (line 12) | public class FindMinRecursionTest { method numberTests (line 14) | @ParameterizedTest method inputStream (line 20) | private static Stream inputStream() { method testFindMaxThrowsExceptionForEmptyInput (line 24) | @Test FILE: src/test/java/com/thealgorithms/maths/FindMinTest.java class FindMinTest (line 12) | public class FindMinTest { method numberTests (line 14) | @ParameterizedTest method inputStream (line 20) | private static Stream inputStream() { method testFindMinThrowsExceptionForEmptyInput (line 25) | @Test FILE: src/test/java/com/thealgorithms/maths/FloorTest.java class FloorTest (line 6) | public class FloorTest { method testFloorWholeNumber (line 7) | @Test method testFloorDoubleNumber (line 16) | @Test method testFloorNegativeZero (line 24) | @Test FILE: src/test/java/com/thealgorithms/maths/FrizzyNumberTest.java class FrizzyNumberTest (line 6) | public class FrizzyNumberTest { method testFrizziesForBase2 (line 7) | @Test method testFrizziesForBase3 (line 14) | @Test method testFrizziesForBase69 (line 21) | @Test FILE: src/test/java/com/thealgorithms/maths/GCDRecursionTest.java class GCDRecursionTest (line 11) | public class GCDRecursionTest { method testGcdPositiveNumbers (line 13) | @ParameterizedTest method testGcdOneZero (line 19) | @ParameterizedTest method testGcdBothZero (line 25) | @Test method testGcdNegativeNumbers (line 30) | @ParameterizedTest method testGcdWithSameNumbers (line 37) | @ParameterizedTest method testGcdWithPrimeNumbers (line 43) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/maths/GCDTest.java class GCDTest (line 6) | public class GCDTest { method testNegativeAndZeroThrowsException (line 8) | @Test method testPositiveAndNegativeThrowsException (line 13) | @Test method testBothNegativeThrowsException (line 18) | @Test method testZeroAndPositiveReturnsPositive (line 23) | @Test method testPositiveAndZeroReturnsPositive (line 28) | @Test method testOneAndZeroReturnsOne (line 33) | @Test method testTwoPositiveNumbers (line 38) | @Test method testMultipleArgumentsGcd (line 43) | @Test method testArrayInputGcd (line 48) | @Test method testArrayWithCommonFactor (line 53) | @Test method testEmptyArrayReturnsZero (line 58) | @Test method testSameNumbers (line 63) | @Test method testPrimeNumbersHaveGcdOne (line 68) | @Test method testSingleElementArrayReturnsElement (line 73) | @Test method testLargeNumbers (line 78) | @Test FILE: src/test/java/com/thealgorithms/maths/GaussianTest.java class GaussianTest (line 9) | public class GaussianTest { method passTest1 (line 12) | @Test FILE: src/test/java/com/thealgorithms/maths/GenericRootTest.java class GenericRootTest (line 10) | public class GenericRootTest { method testGenericRoot (line 11) | @ParameterizedTest method testGenericRootWithNegativeInputs (line 17) | @ParameterizedTest method tcStream (line 23) | private static Stream tcStream() { FILE: src/test/java/com/thealgorithms/maths/GermainPrimeAndSafePrimeTest.java class GermainPrimeAndSafePrimeTest (line 12) | class GermainPrimeAndSafePrimeTest { method provideNumbersForGermainPrimes (line 14) | static Stream provideNumbersForGermainPrimes() { method provideNumbersForSafePrimes (line 19) | static Stream provideNumbersForSafePrimes() { method provideNegativeNumbers (line 24) | static Stream provideNegativeNumbers() { method testValidGermainPrimes (line 28) | @ParameterizedTest method testValidSafePrimes (line 35) | @ParameterizedTest method testNegativeNumbersThrowException (line 42) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/maths/GoldbachConjectureTest.java class GoldbachConjectureTest (line 9) | public class GoldbachConjectureTest { method testValidEvenNumbers (line 10) | @Test method testInvalidOddNumbers (line 17) | @Test method testLesserThanTwo (line 22) | @Test FILE: src/test/java/com/thealgorithms/maths/HappyNumberTest.java class HappyNumberTest (line 8) | public class HappyNumberTest { method testHappyNumbers (line 10) | @Test method testUnhappyNumbers (line 19) | @Test method testLargeNumber (line 27) | @Test FILE: src/test/java/com/thealgorithms/maths/HarshadNumberTest.java class HarshadNumberTest (line 11) | class HarshadNumberTest { method testValidHarshadNumbers (line 13) | @Test method testInvalidHarshadNumbers (line 44) | @Test method testZeroThrowsException (line 55) | @Test method testNegativeNumbersThrowException (line 60) | @Test method testValidHarshadNumbersWithString (line 67) | @Test method testInvalidHarshadNumbersWithString (line 85) | @Test method testStringWithZeroThrowsException (line 94) | @Test method testStringWithNegativeNumbersThrowsException (line 99) | @Test method testNullStringThrowsException (line 106) | @Test method testEmptyStringThrowsException (line 111) | @Test method testInvalidStringThrowsException (line 116) | @Test method testMaxLongValue (line 124) | @Test FILE: src/test/java/com/thealgorithms/maths/HeronsFormulaTest.java class HeronsFormulaTest (line 9) | class HeronsFormulaTest { method testRightTriangleThreeFourFive (line 13) | @Test method testTriangleTwentyFourThirtyEighteen (line 18) | @Test method testEquilateralTriangle (line 23) | @Test method testScaleneTriangleFourFiveEight (line 28) | @Test method testEquilateralTriangleLargeSides (line 33) | @Test method testIsoscelesTriangle (line 40) | @Test method testSmallTriangle (line 45) | @Test method testLargeTriangle (line 50) | @Test method testDecimalSides (line 55) | @Test method testDegenerateTriangleEqualToSumOfOtherTwo (line 62) | @Test method testDegenerateTriangleVariant2 (line 67) | @Test method testDegenerateTriangleVariant3 (line 72) | @Test method testDegenerateTriangleVariant4 (line 77) | @Test method testInvalidTriangleSideGreaterThanSum (line 82) | @Test method testZeroFirstSide (line 87) | @Test method testZeroSecondSide (line 92) | @Test method testZeroThirdSide (line 97) | @Test method testNegativeFirstSide (line 102) | @Test method testNegativeSecondSide (line 107) | @Test method testNegativeThirdSide (line 112) | @Test method testAllNegativeSides (line 117) | @Test method testAllZeroSides (line 122) | @Test method testVerySmallTriangle (line 127) | @Test method testRightTriangleFiveTwelveThirteen (line 134) | @Test method testRightTriangleEightFifteenSeventeen (line 139) | @Test FILE: src/test/java/com/thealgorithms/maths/JosephusProblemTest.java class JosephusProblemTest (line 7) | public class JosephusProblemTest { method testJosephusProblem (line 9) | @Test FILE: src/test/java/com/thealgorithms/maths/JugglerSequenceTest.java class JugglerSequenceTest (line 9) | class JugglerSequenceTest { method testJugglerSequenceWithThree (line 11) | @Test method testJugglerSequenceWithTwo (line 19) | @Test method testJugglerSequenceWithNine (line 27) | @Test method testJugglerSequenceWithOne (line 35) | @Test FILE: src/test/java/com/thealgorithms/maths/KaprekarNumbersTest.java class KaprekarNumbersTest (line 16) | class KaprekarNumbersTest { method testZeroIsKaprekarNumber (line 18) | @Test method testOneIsKaprekarNumber (line 23) | @Test method testNineIsKaprekarNumber (line 28) | @Test method testFortyFiveIsKaprekarNumber (line 34) | @Test method testFiftyFiveIsKaprekarNumber (line 40) | @Test method testNinetyNineIsKaprekarNumber (line 46) | @Test method testTwoNinetySevenIsKaprekarNumber (line 52) | @Test method testSevenZeroThreeIsKaprekarNumber (line 58) | @Test method testNineNineNineIsKaprekarNumber (line 64) | @Test method testTwoTwoTwoThreeIsKaprekarNumber (line 70) | @Test method testEightFiveSevenOneFortyThreeIsKaprekarNumber (line 77) | @Test method testTwoIsNotKaprekarNumber (line 82) | @Test method testThreeIsNotKaprekarNumber (line 87) | @Test method testTenIsNotKaprekarNumber (line 92) | @Test method testTwentySixIsNotKaprekarNumber (line 97) | @Test method testNinetyEightIsNotKaprekarNumber (line 102) | @Test method testOneHundredIsNotKaprekarNumber (line 107) | @Test method testNegativeNumberThrowsException (line 112) | @Test method testKaprekarNumbersInSmallRange (line 117) | @Test method testKaprekarNumbersInMediumRange (line 124) | @Test method testKaprekarNumbersInLargeRange (line 131) | @Test method testKaprekarNumbersInSingleElementRange (line 138) | @Test method testKaprekarNumbersInRangeWithNoKaprekarNumbers (line 145) | @Test method testKaprekarNumbersInRangeStartingFromZero (line 151) | @Test method testInvalidRangeThrowsException (line 158) | @Test method testNegativeStartThrowsException (line 163) | @Test method testEmptyRange (line 168) | @Test method testLargeKaprekarNumber (line 174) | @Test method testFourDigitKaprekarNumbers (line 180) | @Test FILE: src/test/java/com/thealgorithms/maths/KaratsubaMultiplicationTest.java class KaratsubaMultiplicationTest (line 20) | class KaratsubaMultiplicationTest { method provideTestCases (line 28) | static Stream provideTestCases() { method testKaratsubaMultiplication (line 53) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/maths/KeithNumberTest.java class KeithNumberTest (line 12) | class KeithNumberTest { method testSingleDigitKeithNumbers (line 18) | @Test method testTwoDigitKeithNumbers (line 35) | @Test method testThreeDigitKeithNumbers (line 49) | @Test method testFourDigitKeithNumbers (line 60) | @Test method testTwoDigitNonKeithNumbers (line 70) | @Test method testThreeDigitNonKeithNumbers (line 85) | @Test method testKeithNumber14 (line 101) | @Test method testKeithNumber197 (line 110) | @Test method testZeroThrowsException (line 118) | @Test method testNegativeNumbersThrowException (line 126) | @Test method testLargerNumbers (line 136) | @Test method testAllKnownTwoDigitKeithNumbers (line 146) | @Test FILE: src/test/java/com/thealgorithms/maths/KrishnamurthyNumberTest.java class KrishnamurthyNumberTest (line 11) | class KrishnamurthyNumberTest { method testIsKrishnamurthyWith145 (line 17) | @Test method testIsKrishnamurthyWithNonKrishnamurthyNumber (line 25) | @Test method testIsKrishnamurthyWithZero (line 33) | @Test method testIsKrishnamurthyWithNegativeNumbers (line 41) | @Test method testIsKrishnamurthyWithSingleDigitKrishnamurthyNumbers (line 52) | @Test method testIsKrishnamurthyWithSingleDigitNonKrishnamurthyNumbers (line 61) | @Test method testIsKrishnamurthyWithLargestKrishnamurthyNumber (line 76) | @Test method testIsKrishnamurthyWithVariousNonKrishnamurthyNumbers (line 84) | @Test method testIsKrishnamurthyWithNumbersCloseToKrishnamurthy (line 102) | @Test method testAllKnownKrishnamurthyNumbers (line 113) | @Test FILE: src/test/java/com/thealgorithms/maths/LeastCommonMultipleTest.java class LeastCommonMultipleTest (line 10) | class LeastCommonMultipleTest { method testLcm (line 12) | @ParameterizedTest method provideTestCases (line 18) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/maths/LeonardoNumberTest.java class LeonardoNumberTest (line 12) | class LeonardoNumberTest { method testLeonardoNumberNegative (line 16) | @Test method testLeonardoNumberNegativeLarge (line 21) | @Test method testLeonardoNumberZero (line 26) | @Test method testLeonardoNumberOne (line 31) | @Test method testLeonardoNumberTwo (line 36) | @Test method testLeonardoNumberThree (line 41) | @Test method testLeonardoNumberFour (line 46) | @Test method testLeonardoNumberFive (line 51) | @Test method testLeonardoNumberSix (line 56) | @Test method testLeonardoNumberSeven (line 61) | @Test method testLeonardoNumberEight (line 66) | @Test method testLeonardoNumberTen (line 71) | @Test method testLeonardoNumberFifteen (line 76) | @Test method testLeonardoNumberTwenty (line 81) | @Test method testLeonardoNumberIterativeNegative (line 88) | @Test method testLeonardoNumberIterativeNegativeLarge (line 93) | @Test method testLeonardoNumberIterativeZero (line 98) | @Test method testLeonardoNumberIterativeOne (line 103) | @Test method testLeonardoNumberIterativeTwo (line 108) | @Test method testLeonardoNumberIterativeThree (line 113) | @Test method testLeonardoNumberIterativeFour (line 118) | @Test method testLeonardoNumberIterativeFive (line 123) | @Test method testLeonardoNumberIterativeSix (line 128) | @Test method testLeonardoNumberIterativeSeven (line 133) | @Test method testLeonardoNumberIterativeEight (line 138) | @Test method testLeonardoNumberIterativeTen (line 143) | @Test method testLeonardoNumberIterativeFifteen (line 148) | @Test method testLeonardoNumberIterativeTwenty (line 153) | @Test method testLeonardoNumberIterativeTwentyFive (line 158) | @Test method testConsistencyBetweenImplementations (line 165) | @Test FILE: src/test/java/com/thealgorithms/maths/LinearDiophantineEquationsSolverTest.java class LinearDiophantineEquationsSolverTest (line 18) | class LinearDiophantineEquationsSolverTest { method testBasicEquation (line 24) | @Test method testNoSolution (line 39) | @Test method testInfiniteSolutions (line 51) | @Test method testZeroCoefficient (line 63) | @Test method testZeroCoefficientB (line 77) | @Test method testNegativeCoefficients (line 90) | @Test method testNegativeResult (line 103) | @Test method testCoprimeCoefficients (line 117) | @Test method testLargerCoefficients (line 131) | @Test method testNoSolutionGcdCheck (line 145) | @Test method testSimpleCase (line 157) | @Test method testSolutionEquality (line 170) | @Test method testSolutionHashCode (line 186) | @Test method testSolutionToString (line 197) | @Test method testGcdSolutionWrapperEquality (line 210) | @Test method testGcdSolutionWrapperHashCode (line 227) | @Test method testGcdSolutionWrapperToString (line 239) | @Test method testEquationRecord (line 252) | @Test method testZeroResult (line 265) | @Test method testSolutionSetters (line 278) | @Test method testGcdSolutionWrapperSetters (line 292) | @Test method testBothCoefficientsNegative (line 308) | @Test method testLargePrimeCoefficients (line 321) | @Test FILE: src/test/java/com/thealgorithms/maths/LongDivisionTest.java class LongDivisionTest (line 7) | public class LongDivisionTest { method testOne (line 11) | @Test method testTwo (line 18) | @Test method testThree (line 25) | @Test method testNegativeDividend (line 32) | @Test method testDividendLessThanDivisor (line 40) | @Test method testDividendIsZero (line 47) | @Test method testDivisionByZero (line 54) | @Test FILE: src/test/java/com/thealgorithms/maths/LucasSeriesTest.java class LucasSeriesTest (line 13) | class LucasSeriesTest { method testFirstLucasNumber (line 18) | @Test method testSecondLucasNumber (line 27) | @Test method testThirdLucasNumber (line 36) | @Test method testFourthLucasNumber (line 45) | @Test method testFifthLucasNumber (line 54) | @Test method testSixthLucasNumber (line 63) | @Test method testSeventhLucasNumber (line 72) | @Test method testEighthLucasNumber (line 81) | @Test method testNinthLucasNumber (line 90) | @Test method testTenthLucasNumber (line 99) | @Test method testEleventhLucasNumber (line 108) | @Test method testLargerLucasNumbers (line 117) | @Test method testRecursiveAndIterativeConsistency (line 132) | @Test method testZeroInputThrowsException (line 142) | @Test method testNegativeInputThrowsException (line 151) | @Test FILE: src/test/java/com/thealgorithms/maths/LuckyNumberTest.java class LuckyNumberTest (line 10) | class LuckyNumberTest { method luckyNumbersTest (line 12) | @ParameterizedTest method nonLuckyNumbersTest (line 19) | @ParameterizedTest method throwsNegativeNumbersNotAllowed (line 26) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/maths/MathBuilderTest.java class MathBuilderTest (line 8) | class MathBuilderTest { method simpleMath (line 10) | @Test method memoryTest (line 16) | @Test method freeFallDistance (line 22) | @Test method batchSalaryProcessing (line 28) | @Test method parenthesis (line 39) | @Test method areaOfCircle (line 46) | @Test FILE: src/test/java/com/thealgorithms/maths/MaxValueTest.java class MaxValueTest (line 7) | public class MaxValueTest { method maxTest (line 8) | @Test FILE: src/test/java/com/thealgorithms/maths/MeansTest.java class MeansTest (line 25) | class MeansTest { method testArithmeticMeanThrowsExceptionForEmptyList (line 31) | @Test method testArithmeticMeanSingleNumber (line 38) | @Test method testArithmeticMeanTwoNumbers (line 44) | @Test method testArithmeticMeanMultipleNumbers (line 50) | @Test method testArithmeticMeanWithTreeSet (line 56) | @Test method testArithmeticMeanWithNegativeNumbers (line 62) | @Test method testArithmeticMeanWithDecimalNumbers (line 68) | @Test method testArithmeticMeanWithVector (line 74) | @Test method testGeometricMeanThrowsExceptionForEmptyList (line 82) | @Test method testGeometricMeanSingleNumber (line 89) | @Test method testGeometricMeanTwoNumbers (line 95) | @Test method testGeometricMeanMultipleNumbers (line 101) | @Test method testGeometricMeanPerfectSquares (line 107) | @Test method testGeometricMeanIdenticalNumbers (line 114) | @Test method testGeometricMeanWithLinkedHashSet (line 120) | @Test method testHarmonicMeanThrowsExceptionForEmptyList (line 129) | @Test method testHarmonicMeanSingleNumber (line 136) | @Test method testHarmonicMeanTwoNumbers (line 142) | @Test method testHarmonicMeanMultipleNumbers (line 149) | @Test method testHarmonicMeanThreeNumbers (line 155) | @Test method testHarmonicMeanIdenticalNumbers (line 162) | @Test method testHarmonicMeanWithLinkedList (line 168) | @Test method testQuadraticMeanThrowsExceptionForEmptyList (line 177) | @Test method testQuadraticMeanSingleNumber (line 184) | @Test method testQuadraticMeanTwoNumbers (line 190) | @Test method testQuadraticMeanMultipleNumbers (line 196) | @Test method testQuadraticMeanThreeNumbers (line 203) | @Test method testQuadraticMeanIdenticalNumbers (line 210) | @Test method testQuadraticMeanWithLinkedList (line 216) | @Test method testArithmeticMeanWithVeryLargeNumbers (line 224) | @Test method testArithmeticMeanWithVerySmallNumbers (line 230) | @Test method testGeometricMeanWithOnes (line 236) | @Test method testAllMeansConsistencyForIdenticalValues (line 242) | @Test method testMeansRelationship (line 256) | @Test FILE: src/test/java/com/thealgorithms/maths/MedianTest.java class MedianTest (line 13) | class MedianTest { method testMedianSingleValue (line 15) | @Test method testMedianSinglePositiveValue (line 21) | @Test method testMedianSingleNegativeValue (line 27) | @Test method testMedianTwoValues (line 33) | @Test method testMedianTwoIdenticalValues (line 39) | @Test method testMedianThreeValues (line 45) | @Test method testMedianThreeUnsortedValues (line 51) | @Test method testMedianDecimalValueReturn (line 57) | @Test method testMedianNegativeValues (line 63) | @Test method testMedianMixedPositiveAndNegativeValues (line 69) | @Test method testMedianMixedUnsortedValues (line 75) | @Test method testMedianLargeOddArray (line 81) | @Test method testMedianLargeEvenArray (line 87) | @Test method testMedianAllSameValues (line 93) | @Test method testMedianWithZeros (line 99) | @Test method testMedianAlreadySorted (line 105) | @Test method testMedianReverseSorted (line 111) | @Test method testMedianWithDuplicates (line 117) | @Test method testMedianEmptyArrayThrows (line 123) | @Test method testMedianNullArrayThrows (line 129) | @Test method testMedianExtremeValues (line 134) | @Test method testMedianTwoNegativeValues (line 140) | @Test method testMedianFourValuesEven (line 146) | @Test method testMedianFiveValuesOdd (line 152) | @Test FILE: src/test/java/com/thealgorithms/maths/MinValueTest.java class MinValueTest (line 7) | public class MinValueTest { method minTest (line 8) | @Test FILE: src/test/java/com/thealgorithms/maths/ModeTest.java class ModeTest (line 10) | public class ModeTest { method basicTest (line 11) | @ParameterizedTest method tcStream (line 17) | private static Stream tcStream() { FILE: src/test/java/com/thealgorithms/maths/NevilleTest.java class NevilleTest (line 8) | public class NevilleTest { method testInterpolateLinear (line 10) | @Test method testInterpolateQuadratic (line 22) | @Test method testInterpolateWithNegativeNumbers (line 34) | @Test method testMismatchedArrayLengths (line 46) | @Test method testEmptyArrays (line 54) | @Test method testDuplicateXCoordinates (line 62) | @Test FILE: src/test/java/com/thealgorithms/maths/NonRepeatingElementTest.java class NonRepeatingElementTest (line 10) | public class NonRepeatingElementTest { method provideTestCases (line 15) | private static Stream provideTestCases() { method testFindNonRepeatingElements (line 19) | @ParameterizedTest method testFindNonRepeatingElementsWithLargeNumbers (line 26) | @Test FILE: src/test/java/com/thealgorithms/maths/NthUglyNumberTest.java class NthUglyNumberTest (line 9) | public class NthUglyNumberTest { method testGetWithNewObject (line 10) | @Test method testGetWithSameObject (line 34) | @Test method testGetWithBase1 (line 57) | @Test method testGetWithBase2 (line 63) | @Test method testGetThrowsAnErrorForNegativeInput (line 69) | @Test method testConstructorThrowsAnErrorForEmptyInput (line 75) | @Test FILE: src/test/java/com/thealgorithms/maths/NumberOfDigitsTest.java class NumberOfDigitsTest (line 11) | @SuppressWarnings({"rawtypes", "unchecked"}) method testNumberOfDigits (line 14) | @ParameterizedTest method testCases (line 21) | private static Stream testCases() { FILE: src/test/java/com/thealgorithms/maths/NumberPersistenceTest.java class NumberPersistenceTest (line 11) | class NumberPersistenceTest { method testMultiplicativePersistenceValid (line 13) | @ParameterizedTest(name = "multiplicativePersistence({0}) = {1}") method testMultiplicativePersistenceNegative (line 20) | @ParameterizedTest(name = "multiplicativePersistence({0}) throws Illeg... method testAdditivePersistenceValid (line 28) | @ParameterizedTest(name = "additivePersistence({0}) = {1}") method testAdditivePersistenceNegative (line 35) | @ParameterizedTest(name = "additivePersistence({0}) throws IllegalArgu... FILE: src/test/java/com/thealgorithms/maths/PalindromeNumberTest.java class PalindromeNumberTest (line 9) | public class PalindromeNumberTest { method testNumbersArePalindromes (line 10) | @Test method testNumbersAreNotPalindromes (line 18) | @Test method testIfNegativeInputThenExceptionExpected (line 25) | @Test FILE: src/test/java/com/thealgorithms/maths/ParseIntegerTest.java class ParseIntegerTest (line 9) | public class ParseIntegerTest { method testNullInput (line 14) | @Test method testEmptyInput (line 20) | @Test method testInputOfIncorrectFormat (line 26) | @Test method testPositiveValueIsSuccessfullyConverted (line 35) | @Test method testNegativeValueIsSuccessfullyConverted (line 44) | @Test FILE: src/test/java/com/thealgorithms/maths/PascalTriangleTest.java class PascalTriangleTest (line 7) | class PascalTriangleTest { method testForOne (line 9) | @Test method testForTwo (line 16) | @Test method testForFive (line 23) | @Test method testForEight (line 36) | @Test FILE: src/test/java/com/thealgorithms/maths/PerfectCubeTest.java class PerfectCubeTest (line 6) | class PerfectCubeTest { method perfectCube (line 8) | @Test FILE: src/test/java/com/thealgorithms/maths/PerfectNumberTest.java class PerfectNumberTest (line 8) | class PerfectNumberTest { method perfectNumber (line 10) | @Test FILE: src/test/java/com/thealgorithms/maths/PerfectSquareTest.java class PerfectSquareTest (line 7) | public class PerfectSquareTest { method positiveTest (line 8) | @ParameterizedTest method negativeTest (line 15) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/maths/PerimeterTest.java class PerimeterTest (line 6) | public class PerimeterTest { method testcase1 (line 9) | @Test method testcase2 (line 14) | @Test method testcase3 (line 20) | @Test method testcase4 (line 25) | @Test method testcase5 (line 31) | @Test method testcase6 (line 36) | @Test method testcase7 (line 42) | @Test method testcase8 (line 47) | @Test FILE: src/test/java/com/thealgorithms/maths/PiApproximationTest.java class PiApproximationTest (line 10) | class PiApproximationTest { method testAllPointsInside (line 18) | @Test method testAllPointsOutside (line 33) | @Test method testMixedPoints (line 47) | @Test method testBoundaryPoint (line 65) | @Test method testSmallRandomSample (line 79) | @Test method testLargeRandomSample (line 91) | @Test method testResultIsPositive (line 103) | @Test method testResultIsBounded (line 114) | @Test method testSinglePointInside (line 125) | @Test method testSinglePointOutside (line 137) | @Test method testGeneratedPointsInRange (line 149) | @Test method testCorrectNumberOfPointsGenerated (line 162) | @Test FILE: src/test/java/com/thealgorithms/maths/PollardRhoTest.java class PollardRhoTest (line 8) | class PollardRhoTest { method testPollardRhoForNumber315MustReturn5 (line 10) | @Test method testPollardRhoForNumber187MustReturn11 (line 23) | @Test method testPollardRhoForNumber239MustThrowException (line 36) | @Test FILE: src/test/java/com/thealgorithms/maths/PowTest.java class PowTest (line 10) | public class PowTest { method testPow (line 11) | @ParameterizedTest method testPowThrowsExceptionForNegativeExponent (line 17) | @Test method testPowHandlesLargeNumbers (line 22) | @Test method testPowHandlesZeroBase (line 27) | @Test method testPowHandlesOneBase (line 32) | @Test FILE: src/test/java/com/thealgorithms/maths/PowerOfFourTest.java class PowerOfFourTest (line 8) | class PowerOfFourTest { method testPowersOfFour (line 10) | @Test method testNonPowersOfFour (line 20) | @Test method testEdgeCases (line 30) | @Test FILE: src/test/java/com/thealgorithms/maths/PowerOfTwoOrNotTest.java class PowerOfTwoOrNotTest (line 8) | public class PowerOfTwoOrNotTest { method testPowerOfTwoOrNotForPowersOfTwo (line 9) | @Test method testPowerOfTwoOrNotForNotPowersOfTwo (line 17) | @Test FILE: src/test/java/com/thealgorithms/maths/PowerUsingRecursionTest.java class PowerUsingRecursionTest (line 12) | class PowerUsingRecursionTest { method testPowerUsingRecursion (line 14) | @Test FILE: src/test/java/com/thealgorithms/maths/PronicNumberTest.java class PronicNumberTest (line 7) | public class PronicNumberTest { method testForPronicNumber (line 9) | @ParameterizedTest method testForNonPronicNumber (line 16) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/maths/PythagoreanTripleTest.java class PythagoreanTripleTest (line 10) | public class PythagoreanTripleTest { method testIsPythagoreanTriple (line 12) | @ParameterizedTest method testUnorderedInputStillValid (line 18) | @Test FILE: src/test/java/com/thealgorithms/maths/QuadraticEquationSolverTest.java class QuadraticEquationSolverTest (line 6) | public class QuadraticEquationSolverTest { method testSolveEquationRealRoots (line 9) | @Test method testSolveEquationEqualRoots (line 24) | @Test method testSolveEquationComplexRoots (line 36) | @Test FILE: src/test/java/com/thealgorithms/maths/ReverseNumberTest.java class ReverseNumberTest (line 10) | public class ReverseNumberTest { method testReverseNumber (line 12) | @ParameterizedTest method testReverseNumberThrowsExceptionForNegativeInput (line 18) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/maths/SecondMinMaxTest.java class SecondMinMaxTest (line 13) | public class SecondMinMaxTest { class TestCase (line 18) | public static class TestCase { method TestCase (line 19) | public TestCase(final int[] inInputArray, final int inSecondMin, fin... method testForEmptyInputArray (line 29) | @Test method testForArrayWithSingleElement (line 35) | @Test method testForArrayWithSameElements (line 41) | @Test method numberTests (line 47) | @ParameterizedTest method inputStream (line 54) | private static Stream inputStream() { FILE: src/test/java/com/thealgorithms/maths/SieveOfAtkinTest.java class SieveOfAtkinTest (line 12) | class SieveOfAtkinTest { method testGeneratePrimesLimit10 (line 14) | @Test method testGeneratePrimesLimit2 (line 22) | @Test method testGeneratePrimesLimit1 (line 29) | @Test method testGeneratePrimesLimit50 (line 35) | @Test method testGeneratePrimesNegativeLimit (line 42) | @Test FILE: src/test/java/com/thealgorithms/maths/SieveOfEratosthenesTest.java class SieveOfEratosthenesTest (line 16) | class SieveOfEratosthenesTest { method testPrimesUpTo10 (line 18) | @Test method testPrimesUpTo30 (line 24) | @Test method testPrimesUpTo2 (line 30) | @Test method testPrimesUpTo1 (line 36) | @Test method testPrimesUpTo0 (line 41) | @Test method testNegativeInput (line 46) | @Test method testCountPrimes (line 51) | @Test method testLargeNumber (line 57) | @Test FILE: src/test/java/com/thealgorithms/maths/SmithNumberTest.java class SmithNumberTest (line 9) | class SmithNumberTest { method positiveSmithNumbersTest (line 11) | @ParameterizedTest method negativeSmithNumbersTest (line 17) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/maths/SolovayStrassenPrimalityTestTest.java class SolovayStrassenPrimalityTestTest (line 16) | class SolovayStrassenPrimalityTestTest { method setUp (line 25) | @BeforeEach method primeNumbers (line 35) | static Object[][] primeNumbers() { method testPrimeNumbersWithDifferentNAndK (line 45) | @ParameterizedTest method compositeNumbers (line 56) | static Object[][] compositeNumbers() { method testCompositeNumbersWithDifferentNAndK (line 66) | @ParameterizedTest method testEdgeCases (line 76) | @Test method testJacobiSymbolCalculation (line 106) | @Test FILE: src/test/java/com/thealgorithms/maths/SquareFreeIntegerTest.java class SquareFreeIntegerTest (line 10) | class SquareFreeIntegerTest { method testIsSquareFreeInteger (line 12) | @Test method testIsSquareFreeIntegerThrowExceptionIfNumberIsZero (line 57) | @Test method testIsSquareFreeIntegerMustThrowExceptionIfNumberIsNegative (line 71) | @Test FILE: src/test/java/com/thealgorithms/maths/SquareRootWithNewtonRaphsonTestMethod.java class SquareRootWithNewtonRaphsonTestMethod (line 6) | public class SquareRootWithNewtonRaphsonTestMethod { method testfor1 (line 8) | @Test method testfor2 (line 13) | @Test method testfor625 (line 18) | @Test FILE: src/test/java/com/thealgorithms/maths/SquareRootwithBabylonianMethodTest.java class SquareRootwithBabylonianMethodTest (line 6) | public class SquareRootwithBabylonianMethodTest { method testfor4 (line 8) | @Test method testfor1 (line 13) | @Test method testfor2 (line 18) | @Test method testfor625 (line 23) | @Test FILE: src/test/java/com/thealgorithms/maths/StandardDeviationTest.java class StandardDeviationTest (line 6) | public class StandardDeviationTest { method test1 (line 8) | @Test method test2 (line 14) | @Test method test3 (line 20) | @Test method test4 (line 26) | @Test FILE: src/test/java/com/thealgorithms/maths/StandardScoreTest.java class StandardScoreTest (line 6) | public class StandardScoreTest { method test1 (line 8) | @Test method test2 (line 13) | @Test method test3 (line 18) | @Test method test4 (line 23) | @Test FILE: src/test/java/com/thealgorithms/maths/StrobogrammaticNumberTest.java class StrobogrammaticNumberTest (line 7) | class StrobogrammaticNumberTest { method testIsStrobogrammatic (line 9) | @Test FILE: src/test/java/com/thealgorithms/maths/SumOfArithmeticSeriesTest.java class SumOfArithmeticSeriesTest (line 8) | public class SumOfArithmeticSeriesTest { method testSumFrom1To10 (line 9) | @Test method testSumOfOddNumbers1To19 (line 14) | @Test method testA (line 19) | @Test method testB (line 24) | @Test method testC (line 29) | @Test method testForZeroTerms (line 34) | @Test method testIfThrowsExceptionForNegativeNumberOfTerms (line 39) | @Test method testWithSingleTerm (line 44) | @Test method testWithZeroCommonDiff (line 49) | @Test FILE: src/test/java/com/thealgorithms/maths/SumOfDigitsTest.java class SumOfDigitsTest (line 9) | class SumOfDigitsTest { method sumOfDigitsTest (line 10) | @ParameterizedTest method sumOfDigitsRecursionTest (line 16) | @ParameterizedTest method sumOfDigitsFastTest (line 22) | @ParameterizedTest method testCases (line 28) | private static Stream testCases() { FILE: src/test/java/com/thealgorithms/maths/SumOfOddNumbersTest.java class SumOfOddNumbersTest (line 12) | public class SumOfOddNumbersTest { method sumOfFirstNOddNumbersTests (line 14) | @ParameterizedTest method inputStream (line 20) | private static Stream inputStream() { method testSumOfFirstNOddNumbersThrowsExceptionForNegativeInput (line 24) | @Test FILE: src/test/java/com/thealgorithms/maths/SumOfSquaresTest.java class SumOfSquaresTest (line 12) | class SumOfSquaresTest { method testPerfectSquares (line 14) | @Test method testTwoSquares (line 24) | @Test method testThreeSquares (line 34) | @Test method testFourSquares (line 44) | @Test method testLargerNumbers (line 54) | @Test method testEdgeCases (line 63) | @Test FILE: src/test/java/com/thealgorithms/maths/SumWithoutArithmeticOperatorsTest.java class SumWithoutArithmeticOperatorsTest (line 7) | public class SumWithoutArithmeticOperatorsTest { method addZerotoZero (line 10) | @Test method addZerotoNumber (line 15) | @Test method addOddtoEven (line 21) | @Test method addEventoOdd (line 27) | @Test method addRandoms (line 33) | @Test FILE: src/test/java/com/thealgorithms/maths/TestArmstrong.java class TestArmstrong (line 7) | public class TestArmstrong { method testArmstrong (line 9) | @Test FILE: src/test/java/com/thealgorithms/maths/TwinPrimeTest.java class TwinPrimeTest (line 7) | class TwinPrimeTest { method shouldReturn7 (line 9) | @Test method shouldReturn5 (line 22) | @Test method shouldReturnNegative1 (line 35) | @Test method shouldReturn19 (line 48) | @Test FILE: src/test/java/com/thealgorithms/maths/UniformNumbersTest.java class UniformNumbersTest (line 7) | class UniformNumbersTest { method testSingleUniformDigitRange (line 9) | @Test method testSmallRange (line 15) | @Test method testRangeWithNoUniformNumbers (line 21) | @Test method testRangeWithAllUniformNumbers (line 27) | @Test method testMultiDigitRangeWithUniformNumbers (line 33) | @Test method testExactUniformBoundary (line 39) | @Test method testLargeRange (line 45) | @Test method testInvalidRange (line 51) | @Test FILE: src/test/java/com/thealgorithms/maths/VampireNumberTest.java class VampireNumberTest (line 6) | class VampireNumberTest { method areVampireNumbers (line 7) | @Test method arePseudoVampireNumbers (line 14) | @Test method areNotVampireNumbers (line 21) | @Test method testSplitIntoSortedDigits (line 27) | @Test FILE: src/test/java/com/thealgorithms/maths/VolumeTest.java class VolumeTest (line 7) | public class VolumeTest { method volume (line 9) | @Test FILE: src/test/java/com/thealgorithms/maths/ZellersCongruenceTest.java class ZellersCongruenceTest (line 11) | class ZellersCongruenceTest { method validDates (line 13) | static Stream validDates() { method invalidDates (line 17) | static Stream invalidDates() { method testValidDates (line 23) | @ParameterizedTest method testInvalidDates (line 30) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/maths/prime/LiouvilleLambdaFunctionTest.java class LiouvilleLambdaFunctionTest (line 9) | class LiouvilleLambdaFunctionTest { method testLiouvilleLambdaMustThrowExceptionIfNumberIsZero (line 11) | @Test method testLiouvilleLambdaMustThrowExceptionIfNumberIsNegative (line 25) | @Test method testLiouvilleLambdaMustReturnNegativeOne (line 39) | @Test method testLiouvilleLambdaMustReturnPositiveOne (line 52) | @Test FILE: src/test/java/com/thealgorithms/maths/prime/MillerRabinPrimalityCheckTest.java class MillerRabinPrimalityCheckTest (line 9) | class MillerRabinPrimalityCheckTest { method testDeterministicMillerRabinForPrimes (line 10) | @Test method testDeterministicMillerRabinForNotPrimes (line 17) | @Test method testMillerRabinForPrimes (line 24) | @Test FILE: src/test/java/com/thealgorithms/maths/prime/MobiusFunctionTest.java class MobiusFunctionTest (line 9) | class MobiusFunctionTest { method testMobiusForZero (line 11) | @Test method testMobiusForNegativeNumber (line 25) | @Test method testMobiusFunction (line 39) | @Test FILE: src/test/java/com/thealgorithms/maths/prime/PrimeCheckTest.java class PrimeCheckTest (line 7) | public class PrimeCheckTest { method test1 (line 9) | @Test method test2 (line 14) | @Test method test3 (line 19) | @Test method test4 (line 24) | @Test method test5 (line 29) | @Test method test6 (line 34) | @Test method test7 (line 39) | @Test FILE: src/test/java/com/thealgorithms/maths/prime/PrimeFactorizationTest.java class PrimeFactorizationTest (line 12) | class PrimeFactorizationTest { method testPrimeFactorization (line 14) | @ParameterizedTest method testPrimeFactorsSize (line 20) | @ParameterizedTest method provideNumbersAndFactors (line 26) | private static Stream provideNumbersAndFactors() { method provideNumbersAndSizes (line 30) | private static Stream provideNumbersAndSizes() { FILE: src/test/java/com/thealgorithms/matrix/InverseOfMatrixTest.java class InverseOfMatrixTest (line 9) | class InverseOfMatrixTest { method testInvert (line 11) | @ParameterizedTest method provideTestCases (line 18) | private static Stream provideTestCases() { method assertMatrixEquals (line 22) | private void assertMatrixEquals(double[][] expected, double[][] actual) { FILE: src/test/java/com/thealgorithms/matrix/LUDecompositionTest.java class LUDecompositionTest (line 7) | public class LUDecompositionTest { method testLUDecomposition (line 9) | @Test method multiplyMatrices (line 28) | private double[][] multiplyMatrices(double[][] a, double[][] b) { FILE: src/test/java/com/thealgorithms/matrix/MatrixMultiplicationTest.java class MatrixMultiplicationTest (line 9) | public class MatrixMultiplicationTest { method testMultiply1by1 (line 13) | @Test method testMultiply2by2 (line 23) | @Test method testMultiply3by2and2by1 (line 33) | @Test method testMultiplyNonRectangularMatrices (line 43) | @Test method testNullMatrixA (line 53) | @Test method testNullMatrixB (line 59) | @Test method testMultiplyNull (line 65) | @Test method testIncompatibleDimensions (line 78) | @Test method testEmptyMatrices (line 85) | @Test method assertMatrixEquals (line 92) | private void assertMatrixEquals(double[][] expected, double[][] actual) { FILE: src/test/java/com/thealgorithms/matrix/MatrixRankTest.java class MatrixRankTest (line 12) | class MatrixRankTest { method validInputStream (line 14) | private static Stream validInputStream() { method invalidInputStream (line 20) | private static Stream invalidInputStream() { method computeRankTests (line 29) | @ParameterizedTest method computeRankWithInvalidMatrix (line 40) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/matrix/MatrixTransposeTest.java class MatrixTransposeTest (line 11) | public class MatrixTransposeTest { method provideValidMatrixTestCases (line 13) | private static Stream provideValidMatrixTestCases() { method provideInvalidMatrixTestCases (line 18) | private static Stream provideInvalidMatrixTestCases() { method testValidMatrixTranspose (line 22) | @ParameterizedTest(name = "Test case {index}: {2}") method testInvalidMatrixTranspose (line 28) | @ParameterizedTest(name = "Test case {index}: {1}") FILE: src/test/java/com/thealgorithms/matrix/MatrixUtilTest.java class MatrixUtilTest (line 10) | class MatrixUtilTest { method add (line 12) | @Test method subtract (line 33) | @Test method multiply (line 55) | @Test FILE: src/test/java/com/thealgorithms/matrix/MedianOfMatrixTest.java class MedianOfMatrixTest (line 12) | public class MedianOfMatrixTest { method testMedianWithOddNumberOfElements (line 14) | @Test method testMedianWithEvenNumberOfElements (line 26) | @Test method testMedianSingleElement (line 37) | @Test method testEmptyMatrixThrowsException (line 45) | @Test FILE: src/test/java/com/thealgorithms/matrix/MirrorOfMatrixTest.java class MirrorOfMatrixTest (line 9) | class MirrorOfMatrixTest { method testMirrorMatrixRegularMatrix (line 11) | @Test method testMirrorMatrixEmptyMatrix (line 19) | @Test method testMirrorMatrixSingleElementMatrix (line 26) | @Test method testMirrorMatrixMultipleRowsOneColumnMatrix (line 34) | @Test method testMirrorMatrixNullInput (line 42) | @Test method testMirrorMatrixThrows (line 49) | @Test FILE: src/test/java/com/thealgorithms/matrix/PrintAMatrixInSpiralOrderTest.java class PrintAMatrixInSpiralOrderTest (line 10) | class PrintAMatrixInSpiralOrderTest { method testSquareMatrix (line 14) | @Test method testRectangularMatrixMoreRows (line 21) | @Test method testRectangularMatrixMoreCols (line 28) | @Test method testSingleRow (line 35) | @Test method testSingleColumn (line 42) | @Test method testEmptyMatrix (line 49) | @Test method testOneElementMatrix (line 56) | @Test method testMatrixWithNegativeNumbers (line 63) | @Test method testLargeSquareMatrix (line 70) | @Test method testSingleRowWithTwoElements (line 77) | @Test FILE: src/test/java/com/thealgorithms/matrix/SolveSystemTest.java class SolveSystemTest (line 10) | class SolveSystemTest { method solveSystem (line 12) | @ParameterizedTest method matrixGenerator (line 18) | private static Stream matrixGenerator() { FILE: src/test/java/com/thealgorithms/matrix/StochasticMatrixTest.java class StochasticMatrixTest (line 8) | class StochasticMatrixTest { method testRowStochasticMatrix (line 10) | @Test method testColumnStochasticMatrix (line 17) | @Test method testInvalidMatrix (line 23) | @Test FILE: src/test/java/com/thealgorithms/misc/ColorContrastRatioTest.java class ColorContrastRatioTest (line 11) | class ColorContrastRatioTest { method relativeLuminanceProvider (line 14) | static Stream relativeLuminanceProvider() { method contrastRatioProvider (line 18) | static Stream contrastRatioProvider() { method testGetRelativeLuminance (line 22) | @ParameterizedTest method testGetContrastRatio (line 28) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/misc/MapReduceTest.java class MapReduceTest (line 8) | public class MapReduceTest { method testCountWordFrequencies (line 9) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/misc/MedianOfRunningArrayTest.java class MedianOfRunningArrayTest (line 13) | public class MedianOfRunningArrayTest { method testWhenInvalidInoutProvidedShouldThrowException (line 16) | @Test method testWithNegativeValues (line 23) | @Test method testWithSingleValues (line 34) | @Test method testWithRandomValues (line 41) | @Test method testWithNegativeAndPositiveValues (line 69) | @Test method testWithDuplicateValues (line 80) | @Test method testWithDuplicateValuesB (line 91) | @Test method testWithLargeValues (line 104) | @Test method testWithLargeCountOfValues (line 117) | @Test method testWithThreeValuesInDescendingOrder (line 126) | @Test method testWithThreeValuesInOrder (line 135) | @Test method testWithThreeValuesNotInOrderA (line 144) | @Test method testWithThreeValuesNotInOrderB (line 153) | @Test method testWithFloatValues (line 162) | @Test method testWithByteValues (line 173) | @Test method testWithLongValues (line 184) | @Test method testWithDoubleValues (line 193) | @Test FILE: src/test/java/com/thealgorithms/misc/PalindromePrimeTest.java class PalindromePrimeTest (line 10) | public class PalindromePrimeTest { method testPrimeWithPrimeNumbers (line 12) | @Test method testPrimeWithNonPrimeNumbers (line 20) | @Test method testReverse (line 28) | @Test method testGeneratePalindromePrimes (line 35) | @Test method testGeneratePalindromePrimesWithZero (line 42) | @Test method testGeneratePalindromePrimesWithNegativeInput (line 48) | @Test FILE: src/test/java/com/thealgorithms/misc/PalindromeSinglyLinkedListTest.java class PalindromeSinglyLinkedListTest (line 9) | public class PalindromeSinglyLinkedListTest { method testWithEmptyList (line 12) | @Test method testWithSingleElement (line 17) | @Test method testWithListWithOddLengthPositive (line 24) | @Test method testWithListWithOddLengthPositive2 (line 33) | @Test method testWithListWithEvenLengthPositive (line 44) | @Test method testWithListWithOddLengthNegative (line 54) | @Test method testWithListWithEvenLengthNegative (line 63) | @Test method testOptimisedWithEmptyList (line 74) | @Test method testOptimisedWithSingleElement (line 79) | @Test method testOptimisedWithOddLengthPositive (line 85) | @Test method testOptimisedWithOddLengthPositive2 (line 95) | @Test method testOptimisedWithEvenLengthPositive (line 109) | @Test method testOptimisedWithOddLengthNegative (line 121) | @Test method testOptimisedWithEvenLengthNegative (line 131) | @Test FILE: src/test/java/com/thealgorithms/misc/RangeInSortedArrayTest.java class RangeInSortedArrayTest (line 11) | public class RangeInSortedArrayTest { method testSortedRange (line 13) | @ParameterizedTest(name = "Test case {index}: {3}") method provideSortedRangeTestCases (line 19) | private static Stream provideSortedRangeTestCases() { method testGetCountLessThan (line 25) | @ParameterizedTest(name = "Test case {index}: {3}") method provideGetCountLessThanTestCases (line 31) | private static Stream provideGetCountLessThanTestCases() { method testSortedRangeEdgeCases (line 36) | @ParameterizedTest(name = "Edge case {index}: {3}") method provideEdgeCasesForSortedRange (line 42) | private static Stream provideEdgeCasesForSortedRange() { method testGetCountLessThanEdgeCases (line 48) | @ParameterizedTest(name = "Edge case {index}: {3}") method provideEdgeCasesForGetCountLessThan (line 54) | private static Stream provideEdgeCasesForGetCountLessThan() { FILE: src/test/java/com/thealgorithms/misc/ShuffleArrayTest.java class ShuffleArrayTest (line 10) | public class ShuffleArrayTest { method testShuffleBasic (line 12) | @Test method testShuffleSingleElement (line 22) | @Test method testShuffleTwoElements (line 32) | @Test method testShuffleEmptyArray (line 45) | @Test method testShuffleLargeArray (line 55) | @Test method testShuffleRetainsElements (line 65) | @Test method contains (line 77) | private boolean contains(int[] arr, int value) { FILE: src/test/java/com/thealgorithms/misc/SparsityTest.java class SparsityTest (line 11) | public class SparsityTest { method testSparsity (line 15) | @ParameterizedTest(name = "Test case {index}: {2}") method provideTestCases (line 21) | private static Stream provideTestCases() { method testSparsityExceptions (line 27) | @ParameterizedTest(name = "Test case {index}: {1}") method provideExceptionTestCases (line 33) | private static Stream provideExceptionTestCases() { FILE: src/test/java/com/thealgorithms/misc/ThreeSumProblemTest.java class ThreeSumProblemTest (line 14) | public class ThreeSumProblemTest { method setup (line 18) | @BeforeEach method testBruteForce (line 23) | @ParameterizedTest method testTwoPointer (line 29) | @ParameterizedTest method testHashMap (line 35) | @ParameterizedTest method bruteForceTestProvider (line 41) | private static Stream bruteForceTestProvider() { method twoPointerTestProvider (line 45) | private static Stream twoPointerTestProvider() { method hashMapTestProvider (line 49) | private static Stream hashMapTestProvider() { FILE: src/test/java/com/thealgorithms/misc/TwoSumProblemTest.java class TwoSumProblemTest (line 14) | public class TwoSumProblemTest { method testTwoSumExists (line 16) | @Test method testTwoSumNoSolution (line 24) | @Test method testTwoSumMultipleSolutions (line 31) | @Test method testTwoSumMultipleSolution (line 39) | @Test method testTwoSumNegativeNumbers (line 47) | @Test method testTwoSumNoSolutionDuplicatedInputs (line 55) | @Test FILE: src/test/java/com/thealgorithms/others/ArrayLeftRotationTest.java class ArrayLeftRotationTest (line 7) | class ArrayLeftRotationTest { method testForOneElement (line 9) | @Test method testForZeroStep (line 16) | @Test method testForEqualSizeStep (line 23) | @Test method testForLowerSizeStep (line 30) | @Test method testForHigherSizeStep (line 39) | @Test method testForEmptyArray (line 48) | @Test FILE: src/test/java/com/thealgorithms/others/ArrayRightRotationTest.java class ArrayRightRotationTest (line 7) | class ArrayRightRotationTest { method testArrayRightRotation (line 9) | @Test method testArrayRightRotationWithZeroSteps (line 18) | @Test method testArrayRightRotationWithEqualSizeSteps (line 27) | @Test method testArrayRightRotationWithLowerSizeSteps (line 36) | @Test method testArrayRightRotationWithHigherSizeSteps (line 45) | @Test FILE: src/test/java/com/thealgorithms/others/BFPRTTest.java class BFPRTTest (line 11) | class BFPRTTest { method testGetMinKNumsByBFPRT (line 13) | @ParameterizedTest method minKNumsTestData (line 20) | private static Stream minKNumsTestData() { method testGetMinKthByBFPRT (line 24) | @ParameterizedTest method minKthTestData (line 31) | private static Stream minKthTestData() { FILE: src/test/java/com/thealgorithms/others/BestFitCPUTest.java class BestFitCPUTest (line 12) | class BestFitCPUTest { method testFitForUseOfOneBlock (line 20) | @Test method testFitForEqualProcecesses (line 30) | @Test method testFitForNoEmptyBlockCell (line 40) | @Test method testFitForSameInputDifferentQuery (line 50) | @Test method testFitForMoreBlocksNoFit (line 60) | @Test FILE: src/test/java/com/thealgorithms/others/BoyerMooreTest.java class BoyerMooreTest (line 9) | public class BoyerMooreTest { method checkWhenMajorityExists (line 11) | @ParameterizedTest method inputStreamWithExistingMajority (line 17) | private static Stream inputStreamWithExistingMajority() { method checkWhenMajorityExists (line 21) | @ParameterizedTest method inputStreamWithoutMajority (line 27) | private static Stream inputStreamWithoutMajority() { FILE: src/test/java/com/thealgorithms/others/CRC16Test.java class CRC16Test (line 7) | class CRC16Test { method testCRC16 (line 8) | @Test FILE: src/test/java/com/thealgorithms/others/CRCAlgorithmTest.java class CRCAlgorithmTest (line 8) | public class CRCAlgorithmTest { method testNoErrorsWithZeroBER (line 10) | @Test method testAllErrorsWithBEROne (line 23) | @Test method testIntermediateBER (line 34) | @Test method testMessageChangedFlag (line 52) | @Test method testSmallMessageSize (line 61) | @Test method testLargeMessageSize (line 71) | @Test method testSingleBitMessage (line 83) | @Test method testPolynomialLongerThanMessage (line 94) | @Test method testPolynomialWithOnlyOnes (line 106) | @Test method testMultipleRefactorCalls (line 117) | @Test method testCounterConsistency (line 133) | @Test method testGetterMethodsInitialState (line 153) | @Test FILE: src/test/java/com/thealgorithms/others/ConwayTest.java class ConwayTest (line 7) | public class ConwayTest { method testGenerateWith1 (line 8) | @Test method testGenerateWith123456 (line 13) | @Test method testGenerateWith1A1Z3E1R1T3G1F1D2E1S1C (line 20) | @Test method testGenerateNextElementWith1 (line 27) | @Test method testGenerateNextElementWith123456 (line 32) | @Test method testGenerateNextElementWith1A1Z3E1R1T3G1F1D2E1S1C (line 37) | @Test FILE: src/test/java/com/thealgorithms/others/CountFriendsPairingTest.java class CountFriendsPairingTest (line 8) | public class CountFriendsPairingTest { method testForOneElement (line 10) | @Test method testForTwoElements (line 16) | @Test method testForThreeElements (line 22) | @Test method testForFourElements (line 28) | @Test method testForFiveElements (line 34) | @Test method testForSixElements (line 40) | @Test method testForSevenElements (line 46) | @Test method testForEightElements (line 52) | @Test FILE: src/test/java/com/thealgorithms/others/FirstFitCPUTest.java class FirstFitCPUTest (line 12) | class FirstFitCPUTest { method testFitForUseOfOneBlock (line 20) | @Test method testFitForEqualProcecesses (line 30) | @Test method testFitForNoEmptyBlockCell (line 40) | @Test method testFitForSameInputDifferentQuery (line 50) | @Test method testFitForMoreBlocksNoFit (line 60) | @Test FILE: src/test/java/com/thealgorithms/others/FloydTriangleTest.java class FloydTriangleTest (line 11) | public class FloydTriangleTest { method testGenerateFloydTriangleWithValidInput (line 13) | @Test method testGenerateFloydTriangleWithOneRow (line 19) | @Test method testGenerateFloydTriangleWithZeroRows (line 25) | @Test method testGenerateFloydTriangleWithNegativeRows (line 31) | @Test method testGenerateFloydTriangleWithMultipleRows (line 37) | @Test method testGenerateFloydTriangleWithMoreMultipleRows (line 43) | @Test FILE: src/test/java/com/thealgorithms/others/HuffmanTest.java class HuffmanTest (line 12) | class HuffmanTest { method testBuildHuffmanTreeWithBasicInput (line 14) | @Test method testGenerateCodesWithBasicInput (line 25) | @Test method testSingleCharacter (line 48) | @Test method testTwoCharacters (line 61) | @Test method testEqualFrequencies (line 80) | @Test method testLargeFrequencyDifference (line 97) | @Test method testNullCharacterArray (line 113) | @Test method testNullFrequencyArray (line 120) | @Test method testEmptyArrays (line 127) | @Test method testMismatchedArrayLengths (line 135) | @Test method testNegativeFrequency (line 143) | @Test method testZeroFrequency (line 151) | @Test method testGenerateCodesWithNullRoot (line 164) | @Test method testPrefixProperty (line 172) | @Test method testBinaryCodesOnly (line 193) | @Test method testMultipleCharactersWithLargeAlphabet (line 207) | @Test FILE: src/test/java/com/thealgorithms/others/InsertDeleteInArrayTest.java class InsertDeleteInArrayTest (line 21) | class InsertDeleteInArrayTest { method testInsertAtBeginning (line 25) | @Test method testInsertAtEnd (line 32) | @Test method testInsertInMiddle (line 39) | @Test method testInsertIntoEmptyArray (line 46) | @Test method testInsertIntoSingleElementArray (line 53) | @Test method testInsertNegativeNumber (line 60) | @Test method testInsertZero (line 67) | @Test method testInsertWithNullArray (line 74) | @Test method testInsertWithNegativePosition (line 80) | @Test method testInsertWithPositionTooLarge (line 87) | @Test method testDeleteFromBeginning (line 96) | @Test method testDeleteFromEnd (line 103) | @Test method testDeleteFromMiddle (line 110) | @Test method testDeleteFromSingleElementArray (line 117) | @Test method testDeleteFromTwoElementArray (line 124) | @Test method testDeleteWithNullArray (line 131) | @Test method testDeleteFromEmptyArray (line 137) | @Test method testDeleteWithNegativePosition (line 144) | @Test method testDeleteWithPositionTooLarge (line 151) | @Test method testDeleteWithPositionEqualToLength (line 158) | @Test method testInsertThenDelete (line 167) | @Test method testMultipleInsertions (line 176) | @Test method testMultipleDeletions (line 185) | @Test method testLargeArray (line 194) | @Test method testArrayWithDuplicates (line 207) | @Test method testNegativeNumbers (line 214) | @Test FILE: src/test/java/com/thealgorithms/others/IterativeFloodFillTest.java class IterativeFloodFillTest (line 8) | class IterativeFloodFillTest { method testForEmptyImage (line 10) | @Test method testForSingleElementImage (line 19) | @Test method testForEmptyRow (line 28) | @Test method testForImageOne (line 37) | @Test method testForImageTwo (line 63) | @Test method testForImageThree (line 89) | @Test method testForSameNewAndOldColor (line 107) | @Test method testForBigImage (line 117) | @Test method testForBelowZeroX (line 124) | @Test method testForBelowZeroY (line 134) | @Test method testForAboveBoundaryX (line 144) | @Test method testForAboveBoundaryY (line 154) | @Test FILE: src/test/java/com/thealgorithms/others/KadaneAlogrithmTest.java class KadaneAlogrithmTest (line 8) | public class KadaneAlogrithmTest { method testForOneElement (line 10) | @Test method testForTwoElements (line 16) | @Test method testForThreeElements (line 22) | @Test method testForFourElements (line 28) | @Test method testForFiveElements (line 34) | @Test method testForSixElements (line 40) | @Test method testForSevenElements (line 46) | @Test method testForEightElements (line 52) | @Test FILE: src/test/java/com/thealgorithms/others/LineSweepTest.java class LineSweepTest (line 10) | public class LineSweepTest { method testIsOverlap (line 17) | @ParameterizedTest method provideOverlapTestData (line 23) | private static Stream provideOverlapTestData() { method testFindMaximumEndPoint (line 28) | @ParameterizedTest method provideMaximumEndPointTestData (line 34) | private static Stream provideMaximumEndPointTestData() { FILE: src/test/java/com/thealgorithms/others/LinkListSortTest.java class LinkListSortTest (line 8) | public class LinkListSortTest { method testForOneElement (line 10) | @Test method testForTwoElements (line 16) | @Test method testForThreeElements (line 22) | @Test method testForFourElements (line 28) | @Test method testForFiveElements (line 34) | @Test method testForSixElements (line 40) | @Test method testForSevenElements (line 46) | @Test method testForEightElements (line 52) | @Test FILE: src/test/java/com/thealgorithms/others/LowestBasePalindromeTest.java class LowestBasePalindromeTest (line 18) | public class LowestBasePalindromeTest { method testIsPalindromicPositive (line 20) | @ParameterizedTest method testIsPalindromicNegative (line 26) | @ParameterizedTest method testIsPalindromicInBasePositive (line 32) | @ParameterizedTest method testIsPalindromicInBaseNegative (line 38) | @ParameterizedTest method testIsPalindromicInBaseThrowsException (line 44) | @ParameterizedTest method testLowestBasePalindrome (line 50) | @ParameterizedTest method testComputeDigitsInBase (line 56) | @ParameterizedTest method testComputeDigitsInBaseThrowsExceptionForNegativeNumber (line 62) | @ParameterizedTest method testComputeDigitsInBaseThrowsExceptionForInvalidBase (line 68) | @ParameterizedTest method testLowestBasePalindromeThrowsExceptionForNegativeNumber (line 74) | @ParameterizedTest method provideListsForIsPalindromicPositive (line 80) | private static Stream provideListsForIsPalindromicPositive() { method provideListsForIsPalindromicNegative (line 84) | private static Stream provideListsForIsPalindromicNegative() { method provideNumbersAndBasesForIsPalindromicInBasePositive (line 88) | private static Stream provideNumbersAndBasesForIsPalindromi... method provideNumbersAndBasesForIsPalindromicInBaseNegative (line 92) | private static Stream provideNumbersAndBasesForIsPalindromi... method provideNumbersAndBasesForExceptions (line 96) | private static Stream provideNumbersAndBasesForExceptions() { method provideNumbersForLowestBasePalindrome (line 100) | private static Stream provideNumbersForLowestBasePalindrome... method provideNumbersForComputeDigitsInBase (line 105) | private static Stream provideNumbersForComputeDigitsInBase() { method provideInvalidNumbersForComputeDigits (line 110) | private static Stream provideInvalidNumbersForComputeDigits... method provideInvalidBasesForComputeDigits (line 114) | private static Stream provideInvalidBasesForComputeDigits() { method provideNegativeNumbersForLowestBasePalindrome (line 118) | private static Stream provideNegativeNumbersForLowestBasePa... FILE: src/test/java/com/thealgorithms/others/MaximumSumOfDistinctSubarraysWithLengthKTest.java class MaximumSumOfDistinctSubarraysWithLengthKTest (line 17) | class MaximumSumOfDistinctSubarraysWithLengthKTest { method testMaximumSubarraySum (line 26) | @ParameterizedTest method inputStream (line 45) | private static Stream inputStream() { method testLargerArray (line 78) | @Test method testNegativeK (line 89) | @Test method testNullArray (line 99) | @Test method testDuplicatesAtBoundaries (line 109) | @Test method testLargeNumbers (line 120) | @Test method testMultipleMaxWindows (line 132) | @Test method testTwoElementsDistinct (line 143) | @Test method testTwoElementsDuplicate (line 153) | @Test FILE: src/test/java/com/thealgorithms/others/MiniMaxAlgorithmTest.java class MiniMaxAlgorithmTest (line 14) | class MiniMaxAlgorithmTest { method setUp (line 20) | @BeforeEach method tearDown (line 26) | @AfterEach method testConstructorCreatesValidScores (line 31) | @Test method testConstructorWithValidScores (line 43) | @Test method testConstructorWithInvalidScoresThrowsException (line 52) | @Test method testConstructorDoesNotModifyOriginalArray (line 58) | @Test method testSetScoresWithValidPowerOfTwo (line 71) | @Test method testSetScoresWithInvalidLength (line 80) | @Test method testSetScoresWithZeroLength (line 89) | @Test method testSetScoresWithVariousInvalidLengths (line 98) | @Test method testSetScoresWithSingleElement (line 119) | @Test method testMiniMaxWithKnownScores (line 128) | @Test method testMiniMaxWithMinimizerFirst (line 139) | @Test method testMiniMaxWithLargerTree (line 150) | @Test method testMiniMaxVerboseOutput (line 163) | @Test method testGetRandomScoresLength (line 176) | @Test method testGetRandomScoresWithDifferentParameters (line 187) | @Test method testMainMethod (line 198) | @Test method testHeightCalculation (line 208) | @Test method testEdgeCaseWithZeroScores (line 220) | @Test method testEdgeCaseWithNegativeScores (line 229) | @Test method testSetScoresWithNegativeLength (line 241) | @Test method testSetScoresWithLargePowerOfTwo (line 254) | @Test method testSetScoresValidEdgeCases (line 267) | @Test method testGetScoresReturnsDefensiveCopy (line 288) | @Test method testSetScoresCreatesDefensiveCopy (line 301) | @Test method testMiniMaxWithAllSameScores (line 313) | @Test method testMiniMaxAtDifferentDepths (line 323) | @Test method testMiniMaxWithMinIntAndMaxInt (line 335) | @Test FILE: src/test/java/com/thealgorithms/others/MosAlgorithmTest.java class MosAlgorithmTest (line 16) | class MosAlgorithmTest { method testRangeSumQueriesBasic (line 18) | @Test method testRangeSumQueriesSingleElement (line 33) | @Test method testRangeSumQueriesFullArray (line 49) | @Test method testRangeSumQueriesOverlapping (line 62) | @Test method testRangeFrequencyQueriesBasic (line 77) | @Test method testRangeFrequencyQueriesNoMatch (line 92) | @Test method testRangeFrequencyQueriesAllMatch (line 106) | @Test method testEmptyArray (line 121) | @Test method testNullInputs (line 132) | @Test method testQueryStructure (line 141) | @Test method testLargerArray (line 151) | @Test method testRangeFrequencyWithDuplicates (line 167) | @Test method testMainMethod (line 182) | @Test FILE: src/test/java/com/thealgorithms/others/NextFitTest.java class NextFitCPUTest (line 12) | class NextFitCPUTest { method testFitForUseOfOneBlock (line 20) | @Test method testFitForEqualProcecesses (line 30) | @Test method testFitForNoEmptyBlockCell (line 40) | @Test method testFitForSameInputDifferentQuery (line 50) | @Test method testFitForMoreBlocksNoFit (line 60) | @Test FILE: src/test/java/com/thealgorithms/others/PageRankTest.java class PageRankTest (line 14) | class PageRankTest { method testSimpleThreeNodeGraph (line 22) | @Test method testTwoNodeGraph (line 44) | @Test method testSingleNode (line 62) | @Test method testHubAndSpokeGraph (line 77) | @Test method testMultipleIterations (line 102) | @Test method testGetPageRank (line 120) | @Test method testGetAllPageRanks (line 137) | @Test method testNoSelfLoops (line 154) | @Test method testInvalidNodeCountTooSmall (line 171) | @Test method testInvalidNodeCountTooLarge (line 179) | @Test method testInvalidDampingFactorNegative (line 187) | @Test method testInvalidDampingFactorTooLarge (line 198) | @Test method testInvalidIterations (line 209) | @Test method testGetPageRankInvalidNode (line 220) | @Test method testGetPageRankNodeLessThanOne (line 231) | @Test method testComplexGraph (line 242) | @Test method testPageRankSum (line 265) | @Test method testGraphWithIsolatedNode (line 290) | @Test method testVerboseMode (line 308) | @Test FILE: src/test/java/com/thealgorithms/others/PasswordGenTest.java class PasswordGenTest (line 9) | public class PasswordGenTest { method failGenerationWithSameMinMaxLengthTest (line 11) | @Test method generateOneCharacterPassword (line 17) | @Test method failGenerationWithMinLengthSmallerThanMaxLengthTest (line 23) | @Test method generatePasswordNonEmptyTest (line 30) | @Test method testGeneratePasswordWithMinGreaterThanMax (line 36) | @Test method testGeneratePasswordWithNegativeLength (line 42) | @Test method testGeneratePasswordWithZeroLength (line 48) | @Test FILE: src/test/java/com/thealgorithms/others/PerlinNoiseTest.java class PerlinNoiseTest (line 9) | class PerlinNoiseTest { method testDimensions (line 11) | @Test method testRange (line 20) | @Test method testDeterminism (line 33) | @Test method testDifferentSeeds (line 48) | @Test method testInterpolateEndpoints (line 68) | @Test method testSingleOctaveLayer (line 76) | @Test method testInvalidInputs (line 93) | @Test FILE: src/test/java/com/thealgorithms/others/QueueUsingTwoStacksTest.java class QueueUsingTwoStacksTest (line 11) | class QueueUsingTwoStacksTest { method setUp (line 15) | @BeforeEach method testIsEmptyInitially (line 20) | @Test method testInsertSingleElement (line 25) | @Test method testRemoveSingleElement (line 32) | @Test method testRemoveMultipleElements (line 39) | @Test method testPeekFrontWithMultipleElements (line 50) | @Test method testPeekBackWithMultipleElements (line 58) | @Test method testPeekFrontAfterRemovals (line 66) | @Test method testIsEmptyAfterRemovals (line 75) | @Test method testRemoveFromEmptyQueue (line 84) | @Test method testPeekFrontFromEmptyQueue (line 89) | @Test method testPeekBackFromEmptyQueue (line 94) | @Test method testIsInStackEmptyInitially (line 99) | @Test method testIsOutStackEmptyInitially (line 104) | @Test method testIsInStackEmptyAfterInsertion (line 109) | @Test method testIsOutStackEmptyAfterInsertion (line 115) | @Test method testIsOutStackEmptyAfterRemoval (line 121) | @Test method testIsInStackEmptyAfterMultipleRemovals (line 128) | @Test method testIsOutStackEmptyAfterMultipleRemovals (line 137) | @Test FILE: src/test/java/com/thealgorithms/others/SkylineProblemTest.java class SkylineProblemTest (line 8) | public class SkylineProblemTest { method testSingleBuildingSkyline (line 10) | @Test method testTwoBuildingsSkyline (line 24) | @Test method testMergeSkyline (line 42) | @Test method testMultipleBuildingsSkyline (line 67) | @Test FILE: src/test/java/com/thealgorithms/others/TwoPointersTest.java class TwoPointersTest (line 10) | public class TwoPointersTest { method testPositivePairExists (line 12) | @Test method testNegativePairExists (line 19) | @Test method testPairDoesNotExist (line 26) | @Test method testNegativeSumPair (line 33) | @Test method testPairDoesNotExistWithPositiveSum (line 40) | @Test method testEmptyArray (line 47) | @Test method testSingleElementArray (line 54) | @Test method testArrayWithDuplicateElements (line 61) | @Test method testPairExistsAtEdges (line 68) | @Test method isPairedSumShouldThrowExceptionWhenArrayIsNull (line 75) | @Test FILE: src/test/java/com/thealgorithms/others/WorstFitCPUTest.java class WorstFitCPUTest (line 12) | class WorstFitCPUTest { method testFitForUseOfOneBlock (line 20) | @Test method testFitForEqualProcecesses (line 30) | @Test method testFitForNoEmptyBlockCell (line 40) | @Test method testFitForSameInputDifferentQuery (line 50) | @Test method testFitForMoreBlocksNoFit (line 60) | @Test method testFitBadCase (line 70) | @Test FILE: src/test/java/com/thealgorithms/physics/CoulombsLawTest.java class CoulombsLawTest (line 13) | final class CoulombsLawTest { method testSimpleRepulsiveForce (line 19) | @Test method testSimpleAttractiveForce (line 32) | @Test method test2DRepulsiveForce (line 41) | @Test method testOverlappingCharges (line 56) | @Test method testCircularOrbitVelocity (line 63) | @Test method testHydrogenAtomVelocity (line 71) | @Test method testInvalidOrbitalVelocityInputs (line 90) | @Test FILE: src/test/java/com/thealgorithms/physics/DampedOscillatorTest.java class DampedOscillatorTest (line 21) | @DisplayName("DampedOscillator — unit tests") method constructorValidation (line 26) | @Test method analyticalUnderdamped (line 35) | @Test method analyticalOverdamped (line 54) | @Test method eulerApproximatesAnalyticalSmallDt (line 72) | @Test method eulerInputValidation (line 104) | @Test method gettersReturnConfiguration (line 117) | @Test method analyticalAtZeroTime (line 127) | @Test FILE: src/test/java/com/thealgorithms/physics/ElasticCollision2DTest.java class ElasticCollision2DTest (line 8) | class ElasticCollision2DTest { method testEqualMassHeadOnCollision (line 10) | @Test method testUnequalMassHeadOnCollision (line 23) | @Test method testMovingApartNoCollision (line 37) | @Test method testGlancingCollision (line 50) | @Test method testOverlappingBodies (line 65) | @Test method testStationaryBodyHit (line 79) | @Test FILE: src/test/java/com/thealgorithms/physics/GravitationTest.java class GravitationTest (line 13) | final class GravitationTest { method testSimpleForceCalculation (line 19) | @Test method test2DForceCalculation (line 31) | @Test method testOverlappingBodies (line 46) | @Test method testCircularOrbitVelocity (line 53) | @Test method testEarthOrbitVelocity (line 61) | @Test method testInvalidOrbitalVelocityInputs (line 75) | @Test FILE: src/test/java/com/thealgorithms/physics/GroundToGroundProjectileMotionTest.java class GroundToGroundProjectileMotionTest (line 14) | public class GroundToGroundProjectileMotionTest { method testTimeOfFlight (line 18) | @Test method testHorizontalRange (line 41) | @Test method testMaxHeight (line 66) | @Test method testTimeOfFlightWithCustomGravity (line 89) | @Test method testVerticalProjectile (line 112) | @Test method testHorizontalProjectile (line 131) | @Test FILE: src/test/java/com/thealgorithms/physics/KinematicsTest.java class KinematicsTest (line 12) | public final class KinematicsTest { method testCalculateFinalVelocity (line 15) | @Test method testCalculateDisplacement (line 21) | @Test method testCalculateFinalVelocitySquared (line 27) | @Test method testCalculateDisplacementFromVelocities (line 33) | @Test method testDeceleration (line 39) | @Test FILE: src/test/java/com/thealgorithms/physics/ProjectileMotionTest.java class ProjectileMotionTest (line 13) | final class ProjectileMotionTest { method testGroundToGroundLaunch (line 17) | @Test method testElevatedLaunch (line 26) | @Test method testVerticalLaunch (line 35) | @Test method testHorizontalLaunch (line 44) | @Test method testDownwardLaunchFromHeight (line 53) | @Test method testInvalidInputs (line 62) | @Test FILE: src/test/java/com/thealgorithms/physics/SimplePendulumRK4Test.java class SimplePendulumRK4Test (line 11) | class SimplePendulumRK4Test { method testConstructor (line 15) | @Test method testConstructorNegativeLength (line 24) | @Test method testConstructorNegativeGravity (line 30) | @Test method testConstructorZeroLength (line 36) | @Test method testGetters (line 42) | @Test method testSingleStep (line 50) | @Test method testEquilibrium (line 61) | @Test method testSmallAngleOscillation (line 75) | @Test method testLargeAngleOscillation (line 95) | @Test method testEnergyConservationSmallAngle (line 119) | @Test method testEnergyConservationLargeAngle (line 137) | @Test method testSimulate (line 155) | @Test method testEnergyAtEquilibrium (line 178) | @Test method testEnergyAtMaxAngle (line 187) | @Test method testEnergyWithVelocity (line 196) | @Test method testStepRejectsNullState (line 205) | @Test method testStepRejectsInvalidStateLength (line 212) | @Test method testStepRejectsNegativeTimeStep (line 219) | @Test method testExtremeLargeAngle (line 226) | @Test method testExtremeHighVelocity (line 238) | @Test method testExtremeSmallTimeStep (line 250) | @Test FILE: src/test/java/com/thealgorithms/physics/SnellLawTest.java class SnellLawTest (line 9) | public class SnellLawTest { method testRefractedAngle (line 11) | @Test method testTotalInternalReflection (line 24) | @Test method testNoTotalInternalReflectionAtLowAngles (line 33) | @Test FILE: src/test/java/com/thealgorithms/physics/ThinLensTest.java class ThinLensTest (line 7) | class ThinLensTest { method testConvexLensRealImage (line 9) | @Test method testMagnification (line 15) | @Test FILE: src/test/java/com/thealgorithms/prefixsum/DifferenceArrayTest.java class DifferenceArrayTest (line 9) | class DifferenceArrayTest { method testStandardRangeUpdate (line 11) | @Test method testMultipleOverlappingUpdates (line 22) | @Test method testIntegerOverflowSafety (line 34) | @Test method testFullRangeUpdate (line 47) | @Test method testBoundaryWriteOptimization (line 58) | @Test method testLargeMassiveUpdate (line 70) | @Test method testNullInputThrowsException (line 83) | @Test method testEmptyInputThrowsException (line 88) | @Test method testInvalidRangeNegativeIndex (line 93) | @Test method testInvalidRangeOutOfBounds (line 99) | @Test method testInvalidRangeStartGreaterThanEnd (line 105) | @Test FILE: src/test/java/com/thealgorithms/prefixsum/PrefixSum2DTest.java class PrefixSum2DTest (line 9) | class PrefixSum2DTest { method testStandardSquare (line 11) | @Test method testRectangularWide (line 25) | @Test method testRectangularTall (line 35) | @Test method testSingleElement (line 45) | @Test method testLargeNumbers (line 54) | @Test method testInvalidInputs (line 66) | @Test method testInvalidRanges (line 74) | @Test FILE: src/test/java/com/thealgorithms/prefixsum/PrefixSumTest.java class PrefixSumTest (line 9) | class PrefixSumTest { method testStandardCase (line 11) | @Test method testNegativeAndZeros (line 24) | @Test method testLargeNumbers (line 35) | @Test method testSingleElement (line 48) | @Test method testNullInput (line 56) | @Test method testEmptyArray (line 62) | @Test method testInvalidIndices (line 70) | @Test FILE: src/test/java/com/thealgorithms/prefixsum/RangeSumQueryTest.java class RangeSumQueryTest (line 11) | class RangeSumQueryTest { method testBasicExample (line 13) | @Test method testSingleElement (line 24) | @Test method testAllZeros (line 32) | @Test method testNegativeNumbers (line 41) | @Test method testEmptyArrayThrowsException (line 50) | @Test method testNullArrayThrowsException (line 58) | @Test method testInvalidIndicesThrowsException (line 64) | @Test FILE: src/test/java/com/thealgorithms/prefixsum/SubarraySumEqualskTest.java class SubarraySumEqualsKTest (line 11) | class SubarraySumEqualsKTest { method testBasicExample (line 13) | @Test method testWithNegativeNumbers (line 20) | @Test method testSingleElementEqualToK (line 27) | @Test method testSingleElementNotEqualToK (line 34) | @Test method testAllZeros (line 41) | @Test method testEmptyArray (line 48) | @Test method testNullArrayThrowsException (line 55) | @Test FILE: src/test/java/com/thealgorithms/puzzlesandgames/TowerOfHanoiTest.java class TowerOfHanoiTest (line 15) | public class TowerOfHanoiTest { method testMoveCountMatchesFormula (line 17) | @ParameterizedTest method diskCountAndMoveCount (line 25) | private static Stream diskCountAndMoveCount() { method testHanoiWithOneDisc (line 29) | @Test method testHanoiWithTwoDiscs (line 39) | @Test method testHanoiWithThreeDiscs (line 49) | @Test method testHanoiWithDifferentPoles (line 59) | @Test method testHanoiWithZeroDiscs (line 68) | @Test method testHanoiWithNegativeDiscsThrows (line 77) | @Test FILE: src/test/java/com/thealgorithms/puzzlesandgames/WordBoggleTest.java class WordBoggleTest (line 15) | class WordBoggleTest { method setup (line 18) | @BeforeEach method testBoggleBoard (line 33) | @ParameterizedTest method provideTestCases (line 41) | private static Stream provideTestCases() { method testBoggleBoardSpecialCases (line 46) | @ParameterizedTest method provideSpecialCases (line 54) | private static Stream provideSpecialCases() { FILE: src/test/java/com/thealgorithms/randomized/KargerMinCutTest.java class KargerMinCutTest (line 11) | public class KargerMinCutTest { method testSimpleGraph (line 13) | @Test method testTriangleGraph (line 26) | @Test method testSquareGraph (line 37) | @Test method testDisconnectedGraph (line 50) | @Test method testCompleteGraph (line 61) | @Test method testSingleNodeGraph (line 72) | @Test method testTwoNodesNoEdge (line 85) | @Test method testComplexGraph (line 98) | @Test FILE: src/test/java/com/thealgorithms/randomized/MonteCarloIntegrationTest.java class MonteCarloIntegrationTest (line 11) | class MonteCarloIntegrationTest { method testConstantFunction (line 15) | @Test method testLinearFunction (line 23) | @Test method testQuadraticFunction (line 31) | @Test method testLargeSampleSize (line 39) | @Test method testReproducibility (line 47) | @Test method testNegativeInterval (line 55) | @Test method testNullFunction (line 63) | @Test method testInvalidInterval (line 69) | @Test method testZeroSampleSize (line 78) | @Test method testNegativeSampleSize (line 85) | @Test FILE: src/test/java/com/thealgorithms/randomized/RandomizedClosestPairTest.java class RandomizedClosestPairTest (line 8) | public class RandomizedClosestPairTest { method testFindClosestPairDistance (line 10) | @Test method testWithIdenticalPoints (line 17) | @Test method testWithDistantPoints (line 24) | @Test FILE: src/test/java/com/thealgorithms/randomized/RandomizedMatrixMultiplicationVerificationTest.java class RandomizedMatrixMultiplicationVerificationTest (line 8) | class RandomizedMatrixMultiplicationVerificationTest { method testCorrectMultiplication (line 10) | @Test method testIncorrectMultiplication (line 18) | @Test method testLargeMatrix (line 26) | @Test FILE: src/test/java/com/thealgorithms/randomized/RandomizedQuickSortTest.java class RandomizedQuickSortTest (line 10) | public class RandomizedQuickSortTest { method testRandomizedQuickSortMultipleElements (line 15) | @Test method testRandomizedQuickSortEmptyArray (line 26) | @Test method testRandomizedQuickSortSingleElement (line 37) | @Test FILE: src/test/java/com/thealgorithms/randomized/ReservoirSamplingTest.java class ReservoirSamplingTest (line 11) | public class ReservoirSamplingTest { method testSampleSizeEqualsStreamLength (line 13) | @Test method testSampleSizeLessThanStreamLength (line 24) | @Test method testSampleSizeGreaterThanStreamLengthThrowsException (line 37) | @Test FILE: src/test/java/com/thealgorithms/recursion/DiceThrowerTest.java class DiceThrowerTest (line 17) | class DiceThrowerTest { method testTargetZero (line 19) | @Test method testTargetOne (line 26) | @Test method testTargetTwo (line 33) | @Test method testTargetThree (line 41) | @Test method testTargetFour (line 51) | @Test method testTargetSix (line 65) | @Test method testTargetSeven (line 75) | @Test method testLargerTarget (line 86) | @Test method testNegativeTarget (line 100) | @Test method testNegativeTargetPrint (line 105) | @Test method testAllCombinationsValid (line 110) | @Test method testPrintDiceCombinations (line 130) | @Test method testPrintDiceCombinationsZero (line 157) | @Test method testMainMethod (line 175) | @Test method testEdgeCaseTargetFive (line 198) | @Test method testTargetGreaterThanSix (line 212) | @Test FILE: src/test/java/com/thealgorithms/recursion/FactorialRecursionTest.java class FactorialRecursionTest (line 12) | public class FactorialRecursionTest { method testFactorialRecursion (line 13) | @ParameterizedTest method inputStream (line 19) | private static Stream inputStream() { method testThrowsForNegativeInput (line 23) | @Test FILE: src/test/java/com/thealgorithms/recursion/FibonacciSeriesTest.java class FibonacciSeriesTest (line 7) | public class FibonacciSeriesTest { method testFibonacci (line 9) | @Test FILE: src/test/java/com/thealgorithms/recursion/GenerateSubsetsTest.java class GenerateSubsetsTest (line 10) | public final class GenerateSubsetsTest { method testSubsetsOfABC (line 12) | @Test method testSubsetsOfCBF (line 18) | @Test method testSubsetsWithDuplicateChars (line 24) | @Test method testEmptyInput (line 30) | @Test method assertSubsets (line 36) | private void assertSubsets(String input, Iterable expected) { FILE: src/test/java/com/thealgorithms/recursion/SylvesterSequenceTest.java class SylvesterSequenceTest (line 15) | class SylvesterSequenceTest { method validSylvesterNumbers (line 21) | static Stream validSylvesterNumbers() { method testSylvesterValidNumbers (line 26) | @ParameterizedTest method testSylvesterInvalidZero (line 35) | @ParameterizedTest method testSylvesterLargeNumber (line 44) | @Test FILE: src/test/java/com/thealgorithms/scheduling/AgingSchedulingTest.java class AgingSchedulingTest (line 9) | public class AgingSchedulingTest { method setup (line 13) | @BeforeEach method testAddAndScheduleSingleTask (line 18) | @Test method testAddMultipleTasks (line 24) | @Test method testPriorityAdjustmentWithWait (line 32) | @Test method testEmptyScheduler (line 41) | @Test method testMultipleRounds (line 46) | @Test FILE: src/test/java/com/thealgorithms/scheduling/EDFSchedulingTest.java class EDFSchedulingTest (line 10) | public class EDFSchedulingTest { method setup (line 14) | @BeforeEach method testEDFScheduling (line 19) | @Test method testProcessMissedDeadline (line 44) | @Test method createProcesses (line 56) | private List createProcesses() { FILE: src/test/java/com/thealgorithms/scheduling/FCFSSchedulingTest.java class FCFSSchedulingTest (line 10) | public class FCFSSchedulingTest { method testingProcesses (line 12) | @Test method addProcessesForFCFS (line 34) | private List addProcessesForFCFS() { FILE: src/test/java/com/thealgorithms/scheduling/FairShareSchedulingTest.java class FairShareSchedulingTest (line 9) | public class FairShareSchedulingTest { method setup (line 13) | @BeforeEach method testAllocateResourcesSingleUser (line 18) | @Test method testAllocateResourcesMultipleUsers (line 27) | @Test method testAllocateResourcesZeroWeightUser (line 40) | @Test method testAllocateResourcesEqualWeights (line 50) | @Test FILE: src/test/java/com/thealgorithms/scheduling/GangSchedulingTest.java class GangSchedulingTest (line 10) | public class GangSchedulingTest { method setup (line 14) | @BeforeEach method testAddGangAndTask (line 19) | @Test method testMultipleGangs (line 27) | @Test method testGangWithMultipleTasks (line 37) | @Test method testEmptyGangSchedule (line 46) | @Test FILE: src/test/java/com/thealgorithms/scheduling/HighestResponseRatioNextSchedulingTest.java class HighestResponseRatioNextSchedulingTest (line 7) | public class HighestResponseRatioNextSchedulingTest { method testCalculateTurnAroundTime (line 9) | @Test method testCalculateWaitingTime (line 22) | @Test method testCompleteSchedulingScenario (line 33) | @Test method testZeroProcesses (line 48) | @Test method testAllProcessesArriveAtSameTime (line 61) | @Test method testProcessesWithZeroBurstTime (line 74) | @Test method testProcessesWithLargeGapsBetweenArrivals (line 87) | @Test method testProcessesWithVeryLargeBurstTimes (line 100) | @Test FILE: src/test/java/com/thealgorithms/scheduling/JobSchedulingWithDeadlineTest.java class JobSchedulingWithDeadlineTest (line 7) | class JobSchedulingWithDeadlineTest { method testJobSequencingWithDeadlines1 (line 9) | @Test method testJobSequencingWithDeadlines2 (line 16) | @Test method testJobSequencingWithDeadlinesWithArrivalTimes (line 23) | @Test method testJobSequencingWithDeadlinesNoJobs (line 30) | @Test method testJobSequencingWithDeadlinesSingleJob (line 37) | @Test FILE: src/test/java/com/thealgorithms/scheduling/LotterySchedulingTest.java class LotterySchedulingTest (line 13) | public class LotterySchedulingTest { method setup (line 17) | @BeforeEach method testLotterySchedulingWithMockedRandom (line 22) | @Test method createProcesses (line 52) | private List createProcesses() { FILE: src/test/java/com/thealgorithms/scheduling/MLFQSchedulerTest.java class MLFQSchedulerTest (line 7) | public class MLFQSchedulerTest { method testMLFQScheduling (line 9) | @Test method testProcessCompletionOrder (line 27) | @Test FILE: src/test/java/com/thealgorithms/scheduling/MultiAgentSchedulingTest.java class MultiAgentSchedulingTest (line 10) | public class MultiAgentSchedulingTest { method setup (line 14) | @BeforeEach method testAddAgentAndAssignTask (line 19) | @Test method testMultipleAgentsWithTasks (line 27) | @Test method testAgentWithMultipleTasks (line 37) | @Test method testEmptyAgentSchedule (line 46) | @Test FILE: src/test/java/com/thealgorithms/scheduling/NonPreemptivePrioritySchedulingTest.java class NonPreemptivePrioritySchedulingTest (line 7) | public class NonPreemptivePrioritySchedulingTest { method testCalculateAverageWaitingTime (line 9) | @Test method testCalculateAverageTurnaroundTime (line 21) | @Test method testStartTimeIsCorrect (line 34) | @Test method testWithDelayedArrivalTimes (line 46) | @Test method testWithGapsInArrivals (line 58) | @Test FILE: src/test/java/com/thealgorithms/scheduling/PreemptivePrioritySchedulingTest.java class PreemptivePrioritySchedulingTest (line 18) | class PreemptivePrioritySchedulingTest { method testPreemptivePriorityScheduling (line 19) | @ParameterizedTest method provideProcessesAndExpectedSchedules (line 27) | static Stream provideProcessesAndExpectedSchedules() { FILE: src/test/java/com/thealgorithms/scheduling/ProportionalFairSchedulingTest.java class ProportionalFairSchedulingTest (line 9) | public class ProportionalFairSchedulingTest { method setup (line 13) | @BeforeEach method testAllocateResourcesSingleProcess (line 18) | @Test method testAllocateResourcesMultipleProcesses (line 26) | @Test method testAllocateResourcesZeroWeightProcess (line 36) | @Test method testAllocateResourcesEqualWeights (line 45) | @Test FILE: src/test/java/com/thealgorithms/scheduling/RRSchedulingTest.java class RRSchedulingTest (line 10) | class RRSchedulingTest { method testingProcesses (line 11) | @Test method addProcessesForRR (line 45) | private List addProcessesForRR() { FILE: src/test/java/com/thealgorithms/scheduling/RandomSchedulingTest.java class RandomSchedulingTest (line 13) | public class RandomSchedulingTest { method setup (line 18) | @BeforeEach method testRandomOrder1 (line 23) | @Test method testRandomOrder2 (line 38) | @Test method testSingleTask (line 53) | @Test method testEmptyTaskList (line 67) | @Test method testSameTasksMultipleTimes (line 80) | @Test FILE: src/test/java/com/thealgorithms/scheduling/SJFSchedulingTest.java class SJFSchedulingTest (line 16) | class SJFSchedulingTest { method schedulingTestData (line 18) | private static Stream schedulingTestData() { method testSJFScheduling (line 25) | @ParameterizedTest(name = "Test SJF schedule: {index}") method testProcessArrivalOrderIsSorted (line 33) | @Test method testSchedulingEmptyList (line 43) | @Test FILE: src/test/java/com/thealgorithms/scheduling/SRTFSchedulingTest.java class SRTFSchedulingTest (line 9) | class SRTFSchedulingTest { method initialization (line 12) | public void initialization() { method constructor (line 21) | @Test method evaluateScheduling (line 32) | @Test FILE: src/test/java/com/thealgorithms/scheduling/SelfAdjustingSchedulingTest.java class SelfAdjustingSchedulingTest (line 9) | public class SelfAdjustingSchedulingTest { method setup (line 13) | @BeforeEach method testAddAndScheduleSingleTask (line 18) | @Test method testAddMultipleTasks (line 24) | @Test method testPriorityAdjustment (line 34) | @Test method testEmptyScheduler (line 44) | @Test method testTaskReschedulingAfterWait (line 49) | @Test FILE: src/test/java/com/thealgorithms/scheduling/SlackTimeSchedulingTest.java class SlackTimeSchedulingTest (line 9) | public class SlackTimeSchedulingTest { method setup (line 13) | @BeforeEach method testAddAndScheduleSingleTask (line 18) | @Test method testScheduleMultipleTasks (line 25) | @Test method testScheduleTasksWithSameSlackTime (line 34) | @Test method testEmptyScheduler (line 43) | @Test FILE: src/test/java/com/thealgorithms/scheduling/diskscheduling/CircularLookSchedulingTest.java class CircularLookSchedulingTest (line 10) | public class CircularLookSchedulingTest { method testCircularLookSchedulingMovingUp (line 12) | @Test method testCircularLookSchedulingMovingDown (line 22) | @Test method testCircularLookSchedulingEmptyRequests (line 32) | @Test method testCircularLookSchedulingPrintStatus (line 42) | @Test FILE: src/test/java/com/thealgorithms/scheduling/diskscheduling/CircularScanSchedulingTest.java class CircularScanSchedulingTest (line 10) | public class CircularScanSchedulingTest { method testCircularScanSchedulingMovingUp (line 12) | @Test method testCircularScanSchedulingMovingDown (line 26) | @Test method testCircularScanSchedulingEmptyRequests (line 40) | @Test FILE: src/test/java/com/thealgorithms/scheduling/diskscheduling/LookSchedulingTest.java class LookSchedulingTest (line 10) | public class LookSchedulingTest { method testLookSchedulingMovingUp (line 12) | @Test method testLookSchedulingMovingDown (line 22) | @Test method testLookSchedulingEmptyRequests (line 32) | @Test method testLookSchedulingCurrentPosition (line 42) | @Test method testLookSchedulingPrintStatus (line 50) | @Test FILE: src/test/java/com/thealgorithms/scheduling/diskscheduling/SSFSchedulingTest.java class SSFSchedulingTest (line 11) | public class SSFSchedulingTest { method setUp (line 15) | @BeforeEach method testExecuteWithEmptyList (line 20) | @Test method testExecuteWithSingleRequest (line 27) | @Test method testExecuteWithMultipleRequests (line 34) | @Test method testExecuteWithSameDistanceRequests (line 41) | @Test method testGetCurrentPositionAfterExecution (line 48) | @Test FILE: src/test/java/com/thealgorithms/scheduling/diskscheduling/ScanSchedulingTest.java class ScanSchedulingTest (line 10) | public class ScanSchedulingTest { method testScanSchedulingMovingUp (line 12) | @Test method testScanSchedulingMovingDown (line 22) | @Test method testScanSchedulingEmptyRequests (line 32) | @Test method testScanScheduling (line 42) | @Test FILE: src/test/java/com/thealgorithms/searches/BM25InvertedIndexTest.java class BM25InvertedIndexTest (line 16) | class BM25InvertedIndexTest { method setUp (line 20) | @BeforeAll method testAddMovie (line 33) | @Test method testSearchForTermFound (line 40) | @Test method testSearchRanking (line 48) | @Test method testSearchForTermNotFound (line 69) | @Test method testSearchForCommonTerm (line 75) | @Test method testBM25ScoreCalculation (line 82) | @Test method testCaseInsensitivity (line 89) | @Test FILE: src/test/java/com/thealgorithms/searches/BinarySearch2dArrayTest.java class BinarySearch2dArrayTest (line 9) | public class BinarySearch2dArrayTest { method binarySearch2dArrayTestMiddle (line 11) | @Test method binarySearch2dArrayTestMiddleSide (line 23) | @Test method binarySearch2dArrayTestUpper (line 35) | @Test method binarySearch2dArrayTestUpperSide (line 47) | @Test method binarySearch2dArrayTestLower (line 59) | @Test method binarySearch2dArrayTestLowerSide (line 71) | @Test method binarySearch2dArrayTestNotFound (line 83) | @Test method binarySearch2dArrayTestOneRow (line 98) | @Test method binarySearch2dArrayTestTargetInMiddle (line 114) | @Test method binarySearch2dArrayTestTargetAboveMiddleRowInMiddleColumn (line 131) | @Test method binarySearch2dArrayTestEmptyArray (line 149) | @Test FILE: src/test/java/com/thealgorithms/searches/BinarySearchTest.java class BinarySearchTest (line 11) | class BinarySearchTest { method testBinarySearchFound (line 16) | @Test method testBinarySearchNotFound (line 28) | @Test method testBinarySearchFirstElement (line 40) | @Test method testBinarySearchLastElement (line 52) | @Test method testBinarySearchSingleElementFound (line 64) | @Test method testBinarySearchSingleElementNotFound (line 76) | @Test method testBinarySearchEmptyArray (line 88) | @Test method testBinarySearchLargeArray (line 100) | @Test FILE: src/test/java/com/thealgorithms/searches/BoyerMooreTest.java class BoyerMooreTest (line 7) | public class BoyerMooreTest { method testPatternFound (line 9) | @Test method testPatternNotFound (line 17) | @Test method testPatternAtBeginning (line 25) | @Test method testPatternAtEnd (line 33) | @Test method testEmptyPattern (line 41) | @Test method testStaticSearchMethod (line 49) | @Test FILE: src/test/java/com/thealgorithms/searches/BreadthFirstSearchTest.java class BreadthFirstSearchTest (line 13) | public class BreadthFirstSearchTest { method setUp (line 25) | @BeforeEach method testSearchRoot (line 49) | @Test method testSearchF (line 62) | @Test method testSearchNull (line 75) | @Test method testNullRoot (line 87) | @Test method testSearchValueThatNotExists (line 93) | @Test FILE: src/test/java/com/thealgorithms/searches/DepthFirstSearchTest.java class DepthFirstSearchTest (line 13) | public class DepthFirstSearchTest { method setUp (line 26) | @BeforeEach method testSearchRoot (line 50) | @Test method testSearch4 (line 63) | @Test method testNullRoot (line 76) | @Test method testSearchValueThatNotExists (line 82) | @Test FILE: src/test/java/com/thealgorithms/searches/ExponentialSearchTest.java class ExponentialSearchTest (line 11) | class ExponentialSearchTest { method testExponentialSearchFound (line 16) | @Test method testExponentialSearchFirstElement (line 28) | @Test method testExponentialSearchLastElement (line 40) | @Test method testExponentialSearchSingleElementFound (line 52) | @Test method testExponentialSearchEmptyArray (line 64) | @Test method testExponentialSearchLargeArray (line 76) | @Test FILE: src/test/java/com/thealgorithms/searches/FibonacciSearchTest.java class FibonacciSearchTest (line 12) | class FibonacciSearchTest { method testFibonacciSearchFound (line 17) | @Test method testFibonacciSearchNotFound (line 29) | @Test method testFibonacciSearchFirstElement (line 41) | @Test method testFibonacciSearchLastElement (line 53) | @Test method testFibonacciSearchSingleElementFound (line 65) | @Test method testFibonacciSearchSingleElementNotFound (line 77) | @Test method testFibonacciSearchEmptyArray (line 89) | @Test method testFibonacciSearchUnsortedArray (line 97) | @Test method testFibonacciSearchNullKey (line 105) | @Test method testFibonacciSearchLargeArray (line 116) | @Test FILE: src/test/java/com/thealgorithms/searches/HowManyTimesRotatedTest.java class HowManyTimesRotatedTest (line 7) | public class HowManyTimesRotatedTest { method testHowManyTimesRotated (line 9) | @Test FILE: src/test/java/com/thealgorithms/searches/InterpolationSearchTest.java class InterpolationSearchTest (line 11) | class InterpolationSearchTest { method testInterpolationSearchFound (line 16) | @Test method testInterpolationSearchNotFound (line 28) | @Test method testInterpolationSearchFirstElement (line 39) | @Test method testInterpolationSearchSingleElementNotFound (line 50) | @Test method testInterpolationSearchEmptyArray (line 61) | @Test method testInterpolationSearchLargeUniformArray (line 72) | @Test method testInterpolationSearchLargeNonUniformArray (line 83) | @Test FILE: src/test/java/com/thealgorithms/searches/IterativeBinarySearchTest.java class IterativeBinarySearchTest (line 10) | class IterativeBinarySearchTest { method testBinarySearchFound (line 15) | @Test method testBinarySearchNotFound (line 27) | @Test method testBinarySearchFirstElement (line 38) | @Test method testBinarySearchLastElement (line 49) | @Test method testBinarySearchSingleElementFound (line 60) | @Test method testBinarySearchSingleElementNotFound (line 71) | @Test method testBinarySearchEmptyArray (line 82) | @Test method testBinarySearchLargeArray (line 93) | @Test method testBinarySearchLargeArrayNotFound (line 107) | @Test FILE: src/test/java/com/thealgorithms/searches/IterativeTernarySearchTest.java class IterativeTernarySearchTest (line 10) | class IterativeTernarySearchTest { method testTernarySearchFound (line 15) | @Test method testTernarySearchNotFound (line 27) | @Test method testTernarySearchFirstElement (line 38) | @Test method testTernarySearchLastElement (line 49) | @Test method testTernarySearchSingleElementFound (line 60) | @Test method testTernarySearchSingleElementNotFound (line 71) | @Test method testTernarySearchEmptyArray (line 82) | @Test method testTernarySearchLargeArray (line 93) | @Test method testTernarySearchLargeArrayNotFound (line 107) | @Test FILE: src/test/java/com/thealgorithms/searches/JumpSearchTest.java class JumpSearchTest (line 10) | class JumpSearchTest { method testJumpSearchFound (line 15) | @Test method testJumpSearchFirstElement (line 26) | @Test method testJumpSearchLastElement (line 37) | @Test method testJumpSearchNotFound (line 48) | @Test method testJumpSearchEmptyArray (line 59) | @Test method testJumpSearchLargeArray (line 70) | @Test method testJumpSearchLargeArrayNotFound (line 84) | @Test FILE: src/test/java/com/thealgorithms/searches/KMPSearchTest.java class KMPSearchTest (line 7) | class KMPSearchTest { method kmpSearchTestLast (line 9) | @Test method kmpSearchTestFront (line 20) | @Test method kmpSearchTestMiddle (line 31) | @Test method kmpSearchTestNotFound (line 42) | @Test method kmpSearchTest4 (line 53) | @Test FILE: src/test/java/com/thealgorithms/searches/LinearSearchTest.java class LinearSearchTest (line 11) | class LinearSearchTest { method testLinearSearchFound (line 16) | @Test method testLinearSearchFirstElement (line 27) | @Test method testLinearSearchLastElement (line 38) | @Test method testLinearSearchNotFound (line 49) | @Test method testLinearSearchEmptyArray (line 60) | @Test method testLinearSearchLargeArray (line 71) | @Test method testLinearSearchLargeArrayNotFound (line 85) | @Test method testLinearSearchMultipleOccurrences (line 99) | @Test method testLinearSearchRandomArray (line 110) | @Test FILE: src/test/java/com/thealgorithms/searches/LinearSearchThreadTest.java class LinearSearchThreadTest (line 9) | class LinearSearchThreadTest { method testSearcherFound (line 14) | @Test method testSearcherNotFound (line 26) | @Test method testSearcherSegmentFound (line 38) | @Test method testSearcherEmptySegment (line 50) | @Test method testSearcherRandomNumbers (line 62) | @Test FILE: src/test/java/com/thealgorithms/searches/LowerBoundTest.java class LowerBoundTest (line 7) | class LowerBoundTest { method testLowerBoundElementPresent (line 12) | @Test method testLowerBoundElementGreaterThanMax (line 26) | @Test method testLowerBoundElementLessThanMin (line 38) | @Test method testLowerBoundNonExistentValue (line 50) | @Test FILE: src/test/java/com/thealgorithms/searches/MonteCarloTreeSearchTest.java class MonteCarloTreeSearchTest (line 10) | class MonteCarloTreeSearchTest { method testNodeCreation (line 15) | @Test method testAddChildNodes (line 28) | @Test method testGetPromisingNode (line 45) | @Test method testSimulateRandomPlay (line 69) | @Test method testGetWinnerNode (line 88) | @Test method testMonteCarloTreeSearch (line 115) | @Test FILE: src/test/java/com/thealgorithms/searches/OrderAgnosticBinarySearchTest.java class OrderAgnosticBinarySearchTest (line 7) | public class OrderAgnosticBinarySearchTest { method elementInMiddle (line 8) | @Test method rightHalfDescOrder (line 18) | @Test method leftHalfDescOrder (line 28) | @Test method rightHalfAscOrder (line 38) | @Test method leftHalfAscOrder (line 48) | @Test method elementNotFound (line 58) | @Test FILE: src/test/java/com/thealgorithms/searches/QuickSelectTest.java class QuickSelectTest (line 15) | class QuickSelectTest { method quickSelectMinimumOfOneElement (line 17) | @Test method quickSelectMinimumOfTwoElements (line 24) | @Test method quickSelectMinimumOfThreeElements (line 36) | @Test method quickSelectMinimumOfManyElements (line 51) | @Test method quickSelectMaximumOfOneElement (line 59) | @Test method quickSelectMaximumOfTwoElements (line 66) | @Test method quickSelectMaximumOfThreeElements (line 78) | @Test method quickSelectMaximumOfManyElements (line 93) | @Test method quickSelectMedianOfOneElement (line 101) | @Test method quickSelectMedianOfThreeElements (line 108) | @Test method quickSelectMedianOfManyElements (line 123) | @Test method quickSelect30thPercentileOf10Elements (line 133) | @Test method quickSelect30thPercentileOfManyElements (line 142) | @Test method quickSelect70thPercentileOf10Elements (line 152) | @Test method quickSelect70thPercentileOfManyElements (line 161) | @Test method quickSelectMedianOfThreeCharacters (line 171) | @Test method quickSelectMedianOfManyCharacters (line 178) | @Test method quickSelectNullList (line 187) | @Test method quickSelectEmptyList (line 194) | @Test method quickSelectIndexOutOfLeftBound (line 202) | @Test method quickSelectIndexOutOfRightBound (line 209) | @Test method generateRandomIntegers (line 221) | private static List generateRandomIntegers(int n) { method generateRandomCharacters (line 225) | private static List generateRandomCharacters(int n) { method getSortedCopyOfList (line 229) | private static > List getSortedCopyOfList(C... FILE: src/test/java/com/thealgorithms/searches/RabinKarpAlgorithmTest.java class RabinKarpAlgorithmTest (line 8) | class RabinKarpAlgorithmTest { method rabinKarpAlgorithmTestExample (line 10) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/searches/RandomSearchTest.java class RandomSearchTest (line 9) | class RandomSearchTest { method setUp (line 13) | @BeforeEach method testElementFound (line 18) | @Test method testElementNotFound (line 28) | @Test method testEmptyArray (line 37) | @Test method testSingleElementArrayFound (line 46) | @Test method testSingleElementArrayNotFound (line 55) | @Test method testDuplicateElementsFound (line 64) | @Test method testLargeArray (line 74) | @Test FILE: src/test/java/com/thealgorithms/searches/RecursiveBinarySearchTest.java class RecursiveBinarySearchTest (line 10) | public class RecursiveBinarySearchTest { method testBinarySearch (line 12) | @Test FILE: src/test/java/com/thealgorithms/searches/RotatedBinarySearchTest.java class RotatedBinarySearchTest (line 8) | class RotatedBinarySearchTest { method shouldFindElementInRotatedArrayLeftSide (line 10) | @Test method shouldFindElementInRotatedArrayRightSide (line 17) | @Test method shouldFindElementInNotRotatedArray (line 24) | @Test method shouldReturnMinusOneWhenNotFound (line 31) | @Test method shouldHandleWhenMiddleIsGreaterThanKeyInRightSortedHalf (line 38) | @Test method shouldHandleDuplicates (line 45) | @Test FILE: src/test/java/com/thealgorithms/searches/RowColumnWiseSorted2dArrayBinarySearchTest.java class RowColumnWiseSorted2dArrayBinarySearchTest (line 7) | public class RowColumnWiseSorted2dArrayBinarySearchTest { method rowColumnSorted2dArrayBinarySearchTestMiddle (line 9) | @Test method rowColumnSorted2dArrayBinarySearchTestSide (line 24) | @Test method rowColumnSorted2dArrayBinarySearchTestUpper (line 39) | @Test method rowColumnSorted2dArrayBinarySearchTestUpperSide (line 54) | @Test method rowColumnSorted2dArrayBinarySearchTestLower (line 69) | @Test method rowColumnSorted2dArrayBinarySearchTestLowerSide (line 84) | @Test method rowColumnSorted2dArrayBinarySearchTestNotFound (line 99) | @Test method rowColumnSorted2dArrayBinarySearchTestWideMatrixMiddle (line 123) | @Test method rowColumnSorted2dArrayBinarySearchTestWideMatrixTopRightCorner (line 132) | @Test method rowColumnSorted2dArrayBinarySearchTestWideMatrixBottomLeftCorner (line 141) | @Test method rowColumnSorted2dArrayBinarySearchTestWideMatrixTopLeftCorner (line 150) | @Test method rowColumnSorted2dArrayBinarySearchTestWideMatrixBottomRightCorner (line 159) | @Test method rowColumnSorted2dArrayBinarySearchTestWideMatrixNotFound (line 168) | @Test method rowColumnSorted2dArrayBinarySearchTestTallMatrixMiddle (line 187) | @Test method rowColumnSorted2dArrayBinarySearchTestTallMatrixTopRightCorner (line 196) | @Test method rowColumnSorted2dArrayBinarySearchTestTallMatrixBottomLeftCorner (line 205) | @Test method rowColumnSorted2dArrayBinarySearchTestTallMatrixTopLeftCorner (line 214) | @Test method rowColumnSorted2dArrayBinarySearchTestTallMatrixBottomRightCorner (line 223) | @Test method rowColumnSorted2dArrayBinarySearchTestTallMatrixNotFound (line 232) | @Test FILE: src/test/java/com/thealgorithms/searches/SaddlebackSearchTest.java class SaddlebackSearchTest (line 8) | class SaddlebackSearchTest { method testFindElementExists (line 13) | @Test method testFindElementNotExists (line 24) | @Test method testFindSmallestElement (line 35) | @Test method testFindLargestElement (line 46) | @Test method testFindInEmptyArray (line 57) | @Test method testFindSingleElementExists (line 67) | @Test method testFindSingleElementNotExists (line 78) | @Test FILE: src/test/java/com/thealgorithms/searches/SearchInARowAndColWiseSortedMatrixTest.java class SearchInARowAndColWiseSortedMatrixTest (line 7) | class SearchInARowAndColWiseSortedMatrixTest { method testSearchValueExistsInMatrix (line 11) | @Test method testSearchValueNotExistsInMatrix (line 19) | @Test method testSearchInEmptyMatrix (line 27) | @Test method testSearchInSingleElementMatrixFound (line 35) | @Test method testSearchInSingleElementMatrixNotFound (line 43) | @Test method testSearchInRowWiseSortedMatrix (line 51) | @Test method testSearchInColWiseSortedMatrix (line 59) | @Test FILE: src/test/java/com/thealgorithms/searches/SentinelLinearSearchTest.java class SentinelLinearSearchTest (line 12) | class SentinelLinearSearchTest { method testSentinelLinearSearchFound (line 17) | @Test method testSentinelLinearSearchFirstElement (line 28) | @Test method testSentinelLinearSearchLastElement (line 39) | @Test method testSentinelLinearSearchNotFound (line 50) | @Test method testSentinelLinearSearchEmptyArray (line 61) | @Test method testSentinelLinearSearchSingleElementFound (line 72) | @Test method testSentinelLinearSearchSingleElementNotFound (line 83) | @Test method testSentinelLinearSearchMultipleOccurrences (line 94) | @Test method testSentinelLinearSearchLargeArray (line 105) | @Test method testSentinelLinearSearchLargeArrayNotFound (line 119) | @Test method testSentinelLinearSearchRandomArray (line 133) | @Test method testSentinelLinearSearchNullArray (line 145) | @Test method testSentinelLinearSearchNullKey (line 156) | @Test method testSentinelLinearSearchNullKeyNotFound (line 167) | @Test method testSentinelLinearSearchStringArray (line 178) | @Test method testSentinelLinearSearchStringArrayNotFound (line 189) | @Test method testSentinelLinearSearchArrayIntegrity (line 200) | @Test method testSentinelLinearSearchKeyEqualsLastElement (line 218) | @Test FILE: src/test/java/com/thealgorithms/searches/SquareRootBinarySearchTest.java class SquareRootBinarySearchTest (line 7) | class SquareRootBinarySearchTest { method testPerfectSquare (line 9) | @Test method testNonPerfectSquare (line 16) | @Test method testZero (line 23) | @Test method testOne (line 30) | @Test method testLargeNumberPerfectSquare (line 37) | @Test method testLargeNumberNonPerfectSquare (line 44) | @Test method testNegativeInput (line 51) | @Test FILE: src/test/java/com/thealgorithms/searches/TernarySearchTest.java class TernarySearchTest (line 7) | class TernarySearchTest { method testFindElementInSortedArray (line 9) | @Test method testElementNotFound (line 19) | @Test method testFindFirstElement (line 29) | @Test method testFindLastElement (line 39) | @Test method testFindInLargeArray (line 49) | @Test method testNegativeNumbers (line 62) | @Test method testEdgeCaseEmptyArray (line 72) | @Test FILE: src/test/java/com/thealgorithms/searches/TestSearchInARowAndColWiseSortedMatrix.java class TestSearchInARowAndColWiseSortedMatrix (line 7) | public class TestSearchInARowAndColWiseSortedMatrix { method searchItem (line 8) | @Test method notFound (line 17) | @Test FILE: src/test/java/com/thealgorithms/searches/UnionFindTest.java class UnionFindTest (line 8) | class UnionFindTest { method setUp (line 11) | @BeforeEach method testInitialState (line 16) | @Test method testUnionOperation (line 23) | @Test method testUnionWithRank (line 31) | @Test method testFindOperation (line 43) | @Test method testCountAfterMultipleUnions (line 53) | @Test method testNoUnion (line 64) | @Test method testUnionSameSet (line 69) | @Test method testFindOnSingleElement (line 77) | @Test FILE: src/test/java/com/thealgorithms/searches/UpperBoundTest.java class UpperBoundTest (line 10) | class UpperBoundTest { method setUp (line 15) | @BeforeEach method testUpperBoundFound (line 30) | @Test method testUpperBoundExactMatch (line 39) | @Test method testUpperBoundMultipleValues (line 49) | @Test method testUpperBoundLowerThanMin (line 60) | @Test method testUpperBoundHigherThanMax (line 69) | @Test method testUpperBoundEdgeCase (line 77) | @Test method testUpperBoundSingleElementArray (line 86) | @Test FILE: src/test/java/com/thealgorithms/slidingwindow/CountNiceSubarraysTest.java class CountNiceSubarraysTest (line 7) | public class CountNiceSubarraysTest { method testExampleCase (line 8) | @Test method testAllEvenNumbers (line 14) | @Test method testSingleOdd (line 20) | @Test method testMultipleChoices (line 26) | @Test method testTrailingEvenNumbers (line 32) | @Test method testMultipleWindowShrinks (line 38) | @Test method testEvensBetweenOdds (line 44) | @Test method testShrinkWithTrailingEvens (line 50) | @Test FILE: src/test/java/com/thealgorithms/slidingwindow/LongestSubarrayWithSumLessOrEqualToKTest.java class LongestSubarrayWithSumLessOrEqualToKTest (line 10) | public class LongestSubarrayWithSumLessOrEqualToKTest { method testLongestSubarrayWithSumLEK (line 15) | @Test FILE: src/test/java/com/thealgorithms/slidingwindow/LongestSubstringWithoutRepeatingCharactersTest.java class LongestSubstringWithoutRepeatingCharactersTest (line 12) | public class LongestSubstringWithoutRepeatingCharactersTest { method testLengthOfLongestSubstring (line 14) | @Test FILE: src/test/java/com/thealgorithms/slidingwindow/MaxSumKSizeSubarrayTest.java class MaxSumKSizeSubarrayTest (line 12) | class MaxSumKSizeSubarrayTest { method testMaxSumKSizeSubarray (line 17) | @Test method testMaxSumKSizeSubarrayWithDifferentValues (line 28) | @Test method testMaxSumKSizeSubarrayWithInsufficientElements (line 39) | @Test method testMaxSumKSizeSubarrayWithLargeArray (line 50) | @Test method testMaxSumKSizeSubarrayWithNegativeNumbers (line 61) | @Test method testMaxSumKSizeSubarrayWithKEqualToArrayLength (line 72) | @Test FILE: src/test/java/com/thealgorithms/slidingwindow/MaximumSlidingWindowTest.java class MaximumSlidingWindowTest (line 8) | class MaximumSlidingWindowTest { method setUp (line 14) | @BeforeEach method testMaxSlidingWindowSimpleCase (line 20) | @Test method testMaxSlidingWindowWindowSizeOne (line 29) | @Test method testMaxSlidingWindowWindowSizeEqualsArrayLength (line 38) | @Test method testMaxSlidingWindowEmptyArray (line 47) | @Test method testMaxSlidingWindowWindowSizeLargerThanArray (line 56) | @Test FILE: src/test/java/com/thealgorithms/slidingwindow/MinSumKSizeSubarrayTest.java class MinSumKSizeSubarrayTest (line 12) | class MinSumKSizeSubarrayTest { method testMinSumKSizeSubarray (line 17) | @Test method testMinSumKSizeSubarrayWithDifferentValues (line 28) | @Test method testMinSumKSizeSubarrayWithInsufficientElements (line 39) | @Test method testMinSumKSizeSubarrayWithLargeArray (line 50) | @Test method testMinSumKSizeSubarrayWithNegativeNumbers (line 61) | @Test method testMinSumKSizeSubarrayWithKEqualToArrayLength (line 72) | @Test FILE: src/test/java/com/thealgorithms/slidingwindow/MinimumWindowSubstringTest.java class MinimumWindowSubstringTest (line 15) | public class MinimumWindowSubstringTest { method testMinimumWindowSubstring (line 20) | @Test FILE: src/test/java/com/thealgorithms/slidingwindow/ShortestCoprimeSegmentTest.java class ShortestCoprimeSegmentTest (line 13) | public class ShortestCoprimeSegmentTest { method testShortestCoprimeSegment (line 14) | @Test method testShortestCoprimeSegment2 (line 47) | @Test method testNoCoprimeSegment (line 54) | @Test FILE: src/test/java/com/thealgorithms/sorts/AdaptiveMergeSortTest.java class AdaptiveMergeSortTest (line 8) | public class AdaptiveMergeSortTest { method testSortIntegers (line 10) | @Test method testSortStrings (line 19) | @Test method testSortWithDuplicates (line 28) | @Test method testSortEmptyArray (line 37) | @Test method testSortSingleElement (line 46) | @Test method testSortAlreadySortedArray (line 55) | @Test method testSortReversedSortedArray (line 64) | @Test method testSortAllEqualArray (line 73) | @Test method testSortMixedCaseStrings (line 82) | @Test class Person (line 94) | static class Person implements Comparable { method Person (line 98) | Person(String name, int age) { method compareTo (line 103) | @Override method equals (line 108) | @Override method hashCode (line 120) | @Override method testSortCustomObjects (line 126) | @Test FILE: src/test/java/com/thealgorithms/sorts/BeadSortTest.java class BeadSortTest (line 12) | public class BeadSortTest { method testBeadSort (line 13) | @ParameterizedTest method provideArraysForBeadSort (line 20) | private static Stream provideArraysForBeadSort() { method testWithNegativeNumbers (line 25) | @Test FILE: src/test/java/com/thealgorithms/sorts/BinaryInsertionSortTest.java class BinaryInsertionSortTest (line 3) | class BinaryInsertionSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 6) | @Override FILE: src/test/java/com/thealgorithms/sorts/BitonicSortTest.java class BitonicSortTest (line 3) | public class BitonicSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/BogoSortTest.java class BogoSortTest (line 8) | public class BogoSortTest { method bogoSortEmptyArray (line 12) | @Test method bogoSortSingleIntegerArray (line 20) | @Test method bogoSortSingleStringArray (line 28) | @Test method bogoSortNonDuplicateIntegerArray (line 36) | @Test method bogoSortDuplicateIntegerArray (line 44) | @Test method bogoSortNonDuplicateStringArray (line 52) | @Test method bogoSortDuplicateStringArray (line 60) | @Test method bogoSortAlreadySortedArray (line 68) | @Test method bogoSortReversedSortedArray (line 76) | @Test method bogoSortAllEqualArray (line 84) | @Test method bogoSortMixedCaseStrings (line 92) | @Test class Person (line 103) | static class Person implements Comparable { method Person (line 107) | Person(String name, int age) { method compareTo (line 112) | @Override method equals (line 117) | @Override method hashCode (line 129) | @Override method bogoSortCustomObjects (line 135) | @Test FILE: src/test/java/com/thealgorithms/sorts/BubbleSortRecursiveTest.java class BubbleSortRecursiveTest (line 3) | public class BubbleSortRecursiveTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/BubbleSortTest.java class BubbleSortTest (line 12) | public class BubbleSortTest { method bubbleSortEmptyArray (line 16) | @Test method bubbleSortSingleIntegerElementArray (line 24) | @Test method bubbleSortSingleStringElementArray (line 32) | @Test method bubbleSortIntegerArray (line 40) | @Test method bubbleSortStringArray (line 60) | @Test method bubbleSortAlreadySortedArray (line 96) | @Test method bubbleSortReversedSortedArray (line 104) | @Test method bubbleSortAllEqualArray (line 112) | @Test method bubbleSortMixedCaseStrings (line 120) | @Test class Person (line 131) | static class Person implements Comparable { method Person (line 135) | Person(String name, int age) { method compareTo (line 140) | @Override method equals (line 145) | @Override method hashCode (line 157) | @Override method bubbleSortCustomObjects (line 163) | @Test FILE: src/test/java/com/thealgorithms/sorts/BucketSortTest.java class BucketSortTest (line 3) | public class BucketSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/CircleSortTest.java class CircleSortTest (line 3) | class CircleSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/CocktailShakerSortTest.java class CocktailShakerSortTest (line 3) | public class CocktailShakerSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/CombSortTest.java class CombSortTest (line 3) | public class CombSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/CountingSortTest.java class CountingSortTest (line 9) | public class CountingSortTest { method provideTestCases (line 14) | static Stream provideTestCases() { method testCountingSortException (line 21) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/sorts/CycleSortTest.java class CycleSortTest (line 3) | public class CycleSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/DarkSortTest.java class DarkSortTest (line 8) | class DarkSortTest { method testSortWithIntegers (line 10) | @Test method testEmptyArray (line 21) | @Test method testSingleElementArray (line 32) | @Test method testAlreadySortedArray (line 43) | @Test method testDuplicateElementsArray (line 54) | @Test method testNullArray (line 65) | @Test FILE: src/test/java/com/thealgorithms/sorts/DualPivotQuickSortTest.java class DualPivotQuickSortTest (line 3) | class DualPivotQuickSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/DutchNationalFlagSortTest.java class DutchNationalFlagSortTest (line 7) | public class DutchNationalFlagSortTest { method testOddDnfs (line 9) | @Test method testEvenDnfs (line 22) | @Test method testEvenStringsDnfs (line 35) | @Test method testOddStringsDnfs (line 48) | @Test method testOddMidGivenDnfs (line 61) | @Test method testEvenMidGivenDnfs (line 74) | @Test method testEvenStringsMidGivenDnfs (line 87) | @Test method testOddStringsMidGivenDnfs (line 100) | @Test FILE: src/test/java/com/thealgorithms/sorts/ExchangeSortTest.java class ExchangeSortTest (line 3) | public class ExchangeSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/FlashSortTest.java class FlashSortTest (line 16) | public class FlashSortTest extends SortingAlgorithmTest { method getFlashSort (line 19) | public FlashSort getFlashSort() { method getSortAlgorithm (line 23) | @Override method testDefaultConstructor (line 28) | @Test method testCustomConstructorValidRatio (line 35) | @ParameterizedTest method testCustomConstructorInvalidRatio (line 42) | @ParameterizedTest method dynamicTestsForSorting (line 48) | @TestFactory method createDynamicTestsForRatio (line 62) | private List createDynamicTestsForRatio(double ratio) { method getTestMethodsFromSuperClass (line 70) | private List getTestMethodsFromSuperClass() { FILE: src/test/java/com/thealgorithms/sorts/GnomeSortTest.java class GnomeSortTest (line 10) | public class GnomeSortTest { method gnomeSortEmptyArray (line 14) | @Test method singleIntegerArray (line 22) | @Test method gnomeSortNonDuplicateIntegerArray (line 31) | @Test method gnomeSortDuplicateIntegerArray (line 40) | @Test method gnomeSortNegativeDuplicateIntegerArray (line 49) | @Test method singleStringArray (line 58) | @Test method gnomeSortNonDuplicateStringArray (line 67) | @Test method gnomeSortDuplicateStringArray (line 76) | @Test method testSortAlreadySortedArray (line 85) | @Test method testSortReversedSortedArray (line 94) | @Test method testSortAllEqualArray (line 103) | @Test method testSortMixedCaseStrings (line 112) | @Test class Person (line 124) | static class Person implements Comparable { method Person (line 128) | Person(String name, int age) { method compareTo (line 133) | @Override method equals (line 138) | @Override method hashCode (line 150) | @Override method testSortCustomObjects (line 156) | @Test FILE: src/test/java/com/thealgorithms/sorts/HeapSortTest.java class HeapSortTest (line 3) | public class HeapSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/InsertionSortTest.java class InsertionSortTest (line 11) | class InsertionSortTest { method setUp (line 14) | @BeforeEach method insertionSortSortEmptyArrayShouldPass (line 19) | @Test method testEmptyArray (line 25) | private void testEmptyArray(Function sortAlgorit... method insertionSortClassicalSortSingleValueArrayShouldPass (line 33) | @Test method testSingleValue (line 39) | private void testSingleValue(Function sortAlgori... method insertionSortClassicalWithIntegerArrayShouldPass (line 47) | @Test method testIntegerArray (line 53) | private void testIntegerArray(Function sortAlgor... method insertionSortClassicalForArrayWithNegativeValuesShouldPass (line 61) | @Test method testWithNegativeValues (line 67) | private void testWithNegativeValues(Function sor... method insertionSortClassicalForArrayWithDuplicateValuesShouldPass (line 75) | @Test method testWithDuplicates (line 81) | private void testWithDuplicates(Function sortAlg... method insertionSortClassicalWithStringArrayShouldPass (line 89) | @Test method testWithStringArray (line 95) | private void testWithStringArray(Function sortAlgo... method insertionSortClassicalWithRandomArrayPass (line 103) | @Test method testWithRandomArray (line 109) | private void testWithRandomArray(Function sortAlgo... method testSortAlreadySortedArray (line 116) | @Test method testSortReversedSortedArray (line 124) | @Test method testSortAllEqualArray (line 132) | @Test method testSortMixedCaseStrings (line 140) | @Test class Person (line 151) | static class Person implements Comparable { method Person (line 155) | Person(String name, int age) { method compareTo (line 160) | @Override method equals (line 165) | @Override method hashCode (line 177) | @Override method testSortCustomObjects (line 183) | @Test FILE: src/test/java/com/thealgorithms/sorts/IntrospectiveSortTest.java class IntrospectiveSortTest (line 3) | public class IntrospectiveSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/MergeSortNoExtraSpaceTest.java class MergeSortNoExtraSpaceTest (line 11) | public class MergeSortNoExtraSpaceTest { method provideTestCases (line 15) | static Stream provideTestCases() { method testCountingSort (line 22) | @ParameterizedTest method testNegativeNumbers (line 29) | @Test FILE: src/test/java/com/thealgorithms/sorts/MergeSortRecursiveTest.java class MergeSortRecursiveTest (line 9) | public class MergeSortRecursiveTest { method testMergeSortRecursiveCase1 (line 13) | @Test method testMergeSortRecursiveCase2 (line 23) | @Test FILE: src/test/java/com/thealgorithms/sorts/MergeSortTest.java class MergeSortTest (line 3) | public class MergeSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/OddEvenSortTest.java class OddEvenSortTest (line 8) | public class OddEvenSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 11) | @Override FILE: src/test/java/com/thealgorithms/sorts/PancakeSortTest.java class PancakeSortTest (line 3) | public class PancakeSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/PatienceSortTest.java class PatienceSortTest (line 3) | public class PatienceSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/PigeonholeSortTest.java class PigeonholeSortTest (line 12) | public class PigeonholeSortTest { method testPigeonholeSort (line 14) | @ParameterizedTest method provideArraysForPigeonholeSort (line 21) | private static Stream provideArraysForPigeonholeSort() { method testWithNegativeNumbers (line 26) | @Test FILE: src/test/java/com/thealgorithms/sorts/PriorityQueueSortTest.java class PriorityQueueSortTest (line 7) | class PriorityQueueSortTest { method testNullArray (line 9) | @Test method testSingleElementArray (line 15) | @Test method testSortNormalArray (line 22) | @Test method testEmptyArray (line 29) | @Test method testNegativeNumbers (line 36) | @Test method testAlreadySortedArray (line 43) | @Test method testArrayWithDuplicates (line 50) | @Test FILE: src/test/java/com/thealgorithms/sorts/QuickSortTest.java class QuickSortTest (line 7) | class QuickSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 8) | @Override FILE: src/test/java/com/thealgorithms/sorts/RadixSortTest.java class RadixSortTest (line 12) | public class RadixSortTest { method test (line 13) | @ParameterizedTest method provideTestCases (line 19) | private static Stream provideTestCases() { method testWithNegativeNumbers (line 26) | @Test FILE: src/test/java/com/thealgorithms/sorts/SelectionSortRecursiveTest.java class SelectionSortRecursiveTest (line 3) | public class SelectionSortRecursiveTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override method getGeneratedArraySize (line 9) | protected int getGeneratedArraySize() { FILE: src/test/java/com/thealgorithms/sorts/SelectionSortTest.java class SelectionSortTest (line 3) | class SelectionSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/ShellSortTest.java class ShellSortTest (line 3) | public class ShellSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/SlowSortTest.java class SlowSortTest (line 13) | public class SlowSortTest { method slowSortEmptyArray (line 17) | @Test method slowSortSingleIntegerElementArray (line 25) | @Test method slowSortSingleStringElementArray (line 33) | @Test method slowSortIntegerArray (line 41) | @Test method slowSortDuplicateIntegerArray (line 49) | @Test method slowSortStringArray (line 57) | @Test method slowSortDuplicateStringArray (line 65) | @Test method slowSortStringSymbolArray (line 73) | @Test method testSortAlreadySortedArray (line 81) | @Test method testSortReversedSortedArray (line 89) | @Test method testSortAllEqualArray (line 97) | @Test method testSortMixedCaseStrings (line 105) | @Test class Person (line 116) | static class Person implements Comparable { method Person (line 120) | Person(String name, int age) { method compareTo (line 125) | @Override method equals (line 130) | @Override method hashCode (line 142) | @Override method testSortCustomObjects (line 148) | @Test FILE: src/test/java/com/thealgorithms/sorts/SmoothSortTest.java class SmoothSortTest (line 3) | public class SmoothSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/SortUtilsRandomGeneratorTest.java class SortUtilsRandomGeneratorTest (line 8) | class SortUtilsRandomGeneratorTest { method generateArray (line 10) | @RepeatedTest(1000) method generateArrayEmpty (line 18) | @Test method generateDouble (line 25) | @RepeatedTest(1000) FILE: src/test/java/com/thealgorithms/sorts/SortUtilsTest.java class SortUtilsTest (line 14) | class SortUtilsTest { method isSortedEmptyArray (line 16) | @Test method isSortedWithSingleElement (line 22) | @Test method isSortedArrayTrue (line 28) | @Test method isSortedArrayFalse (line 40) | @Test method isSortedListTrue (line 52) | @Test method isSortedListFalse (line 64) | @Test method testSwap (line 76) | @ParameterizedTest method testSwapFlippedIndices (line 83) | @ParameterizedTest method provideArraysForSwap (line 90) | private static Stream provideArraysForSwap() { FILE: src/test/java/com/thealgorithms/sorts/SortingAlgorithmTest.java class SortingAlgorithmTest (line 14) | public abstract class SortingAlgorithmTest { method getSortAlgorithm (line 15) | abstract SortAlgorithm getSortAlgorithm(); method getGeneratedArraySize (line 17) | protected int getGeneratedArraySize() { method shouldAcceptWhenEmptyArrayIsPassed (line 21) | @Test method shouldAcceptWhenEmptyListIsPassed (line 31) | @Test method shouldAcceptWhenSingleValuedArrayIsPassed (line 41) | @Test method shouldAcceptWhenSingleValuedListIsPassed (line 51) | @Test method shouldAcceptWhenListWithAllPositiveValuesIsPassed (line 61) | @Test method shouldAcceptWhenArrayWithAllPositiveValuesIsPassed (line 71) | @Test method shouldAcceptWhenArrayWithAllNegativeValuesIsPassed (line 81) | @Test method shouldAcceptWhenListWithAllNegativeValuesIsPassed (line 91) | @Test method shouldAcceptWhenArrayWithRealNumberValuesIsPassed (line 101) | @Test method shouldAcceptWhenListWithRealNumberValuesIsPassed (line 111) | @Test method shouldAcceptWhenArrayWithDuplicateValueIsPassed (line 121) | @Test method shouldAcceptWhenListWithDuplicateValueIsPassed (line 131) | @Test method shouldAcceptWhenStringValueArrayIsPassed (line 141) | @Test method shouldAcceptWhenStringValueListIsPassed (line 151) | @Test method shouldAcceptWhenRandomArrayIsPassed (line 161) | @Test method shouldAcceptWhenRandomListIsPassed (line 169) | @Test method shouldAcceptWhenArrayWithAllIdenticalValuesIsPassed (line 178) | @Test method shouldAcceptWhenListWithAllIdenticalValuesIsPassed (line 185) | @Test method shouldAcceptWhenArrayWithMixedPositiveAndNegativeValuesIsPassed (line 192) | @Test method shouldAcceptWhenListWithMixedPositiveAndNegativeValuesIsPassed (line 199) | @Test method shouldAcceptWhenArrayWithLargeNumbersIsPassed (line 206) | @Test method shouldAcceptWhenListWithLargeNumbersIsPassed (line 213) | @Test method shouldAcceptWhenArrayWithMaxIntegerValuesIsPassed (line 220) | @Test method shouldAcceptWhenListWithMaxIntegerValuesIsPassed (line 227) | @Test method shouldAcceptWhenArrayWithMinIntegerValuesIsPassed (line 234) | @Test method shouldAcceptWhenListWithMinIntegerValuesIsPassed (line 241) | @Test method shouldAcceptWhenArrayWithSpecialCharactersIsPassed (line 248) | @Test method shouldAcceptWhenListWithSpecialCharactersIsPassed (line 255) | @Test method shouldAcceptWhenArrayWithMixedCaseStringsIsPassed (line 262) | @Test method shouldAcceptWhenListWithMixedCaseStringsIsPassed (line 269) | @Test method shouldHandleArrayWithNullValues (line 276) | @Test method shouldHandleListWithNullValues (line 282) | @Test class CustomObject (line 288) | static class CustomObject implements Comparable { method CustomObject (line 291) | CustomObject(int value) { method compareTo (line 295) | @Override method toString (line 300) | @Override method equals (line 306) | @Override method hashCode (line 318) | @Override method shouldHandleArrayOfCustomObjects (line 324) | @Test method shouldHandleListOfCustomObjects (line 331) | @Test method shouldHandleArrayOfFloatingPointNumbers (line 338) | @Test method shouldHandleListOfFloatingPointNumbers (line 345) | @Test method shouldHandleArrayWithEmptyStrings (line 352) | @Test method shouldHandleListWithEmptyStrings (line 359) | @Test FILE: src/test/java/com/thealgorithms/sorts/SpreadSortTest.java class SpreadSortTest (line 11) | public class SpreadSortTest extends SortingAlgorithmTest { method getGeneratedArraySize (line 13) | protected int getGeneratedArraySize() { method getSortAlgorithm (line 17) | @Override method wrongConstructorInputs (line 22) | private static Stream wrongConstructorInputs() { method testConstructor (line 27) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/sorts/StalinSortTest.java class StalinSortTest (line 7) | public class StalinSortTest { method testSortIntegers (line 9) | @Test method testSortStrings (line 18) | @Test method testSortWithDuplicates (line 27) | @Test method testSortEmptyArray (line 36) | @Test method testSortSingleElement (line 45) | @Test FILE: src/test/java/com/thealgorithms/sorts/StoogeSortTest.java class StoogeSortTest (line 3) | public class StoogeSortTest extends SortingAlgorithmTest { method getGeneratedArraySize (line 4) | protected int getGeneratedArraySize() { method getSortAlgorithm (line 8) | @Override FILE: src/test/java/com/thealgorithms/sorts/StrandSortTest.java class StrandSortTest (line 3) | class StrandSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/SwapSortTest.java class SwapSortTest (line 3) | public class SwapSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/TimSortTest.java class TimSortTest (line 3) | class TimSortTest extends SortingAlgorithmTest { method getSortAlgorithm (line 4) | @Override FILE: src/test/java/com/thealgorithms/sorts/TopologicalSortTest.java class TopologicalSortTest (line 12) | class TopologicalSortTest { method successTest (line 14) | @Test method failureTest (line 43) | @Test method testEmptyGraph (line 63) | @Test method testSingleNode (line 69) | @Test FILE: src/test/java/com/thealgorithms/sorts/TournamentSortTest.java class TournamentSortTest (line 7) | public class TournamentSortTest extends SortingAlgorithmTest { method shouldAcceptWhenNullArrayIsPassed (line 9) | @Test method getSortAlgorithm (line 15) | @Override FILE: src/test/java/com/thealgorithms/sorts/TreeSortTest.java class TreeSortTest (line 12) | public class TreeSortTest { method treeSortEmptyArray (line 15) | @Test method treeSortSingleStringElement (line 23) | @Test method treeSortStringArray (line 31) | @Test method treeSortIntegerArray (line 39) | @Test method treeSortDoubleArray (line 47) | @Test FILE: src/test/java/com/thealgorithms/sorts/WaveSortTest.java class WaveSortTest (line 12) | public class WaveSortTest { method waveSortTest (line 13) | @ParameterizedTest method getHistogram (line 24) | private Map getHistogram(Integer[] array) { method arraysToWaveSort (line 32) | private static Stream arraysToWaveSort() { method testIsWaveSorted (line 37) | @ParameterizedTest method waveSortedArrays (line 43) | public static Stream waveSortedArrays() { FILE: src/test/java/com/thealgorithms/sorts/WiggleSortTest.java class WiggleSortTest (line 8) | public class WiggleSortTest { method wiggleTestNumbersEven (line 10) | @Test method wiggleTestNumbersOdd (line 19) | @Test method wiggleTestNumbersOddDuplicates (line 28) | @Test method wiggleTestNumbersOddMultipleDuplicates (line 37) | @Test method wiggleTestNumbersEvenMultipleDuplicates (line 46) | @Test method wiggleTestNumbersEvenDuplicates (line 56) | @Test method wiggleTestStrings (line 65) | @Test FILE: src/test/java/com/thealgorithms/stacks/BalancedBracketsTest.java class BalancedBracketsTest (line 12) | class BalancedBracketsTest { method testIsPairedTrue (line 14) | @ParameterizedTest method testIsPairedFalse (line 20) | @ParameterizedTest method testIsBalanced (line 26) | @ParameterizedTest method testIsBalancedNull (line 32) | @Test FILE: src/test/java/com/thealgorithms/stacks/CelebrityFinderTest.java class CelebrityFinderTest (line 10) | public class CelebrityFinderTest { method testCelebrityFinder (line 12) | @ParameterizedTest method providePartyMatrices (line 18) | private static Stream providePartyMatrices() { FILE: src/test/java/com/thealgorithms/stacks/DecimalToAnyUsingStackTest.java class DecimalToAnyUsingStackTest (line 8) | class DecimalToAnyUsingStackTest { method testConvertToBinary (line 10) | @Test method testConvertToOctal (line 16) | @Test method testConvertToDecimal (line 21) | @Test method testConvertToHexadecimal (line 26) | @Test method testInvalidRadix (line 31) | @Test method testNegativeNumber (line 40) | @Test FILE: src/test/java/com/thealgorithms/stacks/DuplicateBracketsTest.java class DuplicateBracketsTest (line 14) | class DuplicateBracketsTest { method testInputReturnsFalse (line 16) | @ParameterizedTest method testInputReturnsTrue (line 22) | @ParameterizedTest method testInvalidInput (line 28) | @Test method testDuplicateBracketsTrueCases (line 33) | @ParameterizedTest(name = "Should be true: \"{0}\"") method provideInputsThatShouldReturnTrue (line 39) | static Stream provideInputsThatShouldReturnTrue() { method testDuplicateBracketsFalseCases (line 43) | @ParameterizedTest(name = "Should be false: \"{0}\"") method provideInputsThatShouldReturnFalse (line 49) | static Stream provideInputsThatShouldReturnFalse() { FILE: src/test/java/com/thealgorithms/stacks/GreatestElementConstantTimeTest.java class GreatestElementConstantTimeTest (line 11) | public class GreatestElementConstantTimeTest { method setConstantTime (line 15) | @BeforeEach method testMaxAtFirst (line 20) | @Test method testMinTwo (line 29) | @Test method testNullMax (line 41) | @Test method testBlankHandle (line 50) | @Test method testPushPopAfterEmpty (line 59) | @Test FILE: src/test/java/com/thealgorithms/stacks/InfixToPostfixTest.java class InfixToPostfixTest (line 11) | class InfixToPostfixTest { method testValidExpressions (line 13) | @ParameterizedTest method provideValidExpressions (line 19) | private static Stream provideValidExpressions() { method testInvalidExpressions (line 23) | @ParameterizedTest method provideInvalidExpressions (line 30) | private static Stream provideInvalidExpressions() { FILE: src/test/java/com/thealgorithms/stacks/InfixToPrefixTest.java class InfixToPrefixTest (line 12) | public class InfixToPrefixTest { method testValidExpressions (line 14) | @ParameterizedTest method testEmptyString (line 20) | @Test method testNullValue (line 26) | @Test method provideValidExpressions (line 32) | private static Stream provideValidExpressions() { FILE: src/test/java/com/thealgorithms/stacks/LargestRectangleTest.java class LargestRectangleTest (line 10) | public class LargestRectangleTest { method testLargestRectangleHistogram (line 12) | @ParameterizedTest(name = "Histogram: {0} → Expected area: {1}") method histogramProvider (line 18) | static Stream histogramProvider() { method createLargeArray (line 23) | private static int[] createLargeArray(int size, int value) { FILE: src/test/java/com/thealgorithms/stacks/MinStackUsingSingleStackTest.java class MinStackUsingSingleStackTest (line 9) | public class MinStackUsingSingleStackTest { method testBasicOperations (line 11) | @Test method testTopElement (line 30) | @Test method testGetMinAfterPops (line 42) | @Test method testEmptyStack (line 59) | @Test FILE: src/test/java/com/thealgorithms/stacks/MinStackUsingTwoStacksTest.java class MinStackUsingTwoStacksTest (line 9) | public class MinStackUsingTwoStacksTest { method testBasicOperations (line 11) | @Test method testPushDuplicateMins (line 28) | @Test method testPopOnEmptyStack (line 51) | @Test method testTopOnEmptyStack (line 57) | @Test method testGetMinOnEmptyStack (line 63) | @Test method testSingleElementStack (line 69) | @Test method testIncreasingSequence (line 80) | @Test method testDecreasingSequence (line 97) | @Test FILE: src/test/java/com/thealgorithms/stacks/NextGreaterElementTest.java class NextGreaterElementTest (line 12) | class NextGreaterElementTest { method testFindNextGreaterElements (line 14) | @ParameterizedTest method provideTestCases (line 20) | static Stream provideTestCases() { method testNullInput (line 25) | @Test FILE: src/test/java/com/thealgorithms/stacks/NextSmallerElementTest.java class NextSmallerElementTest (line 12) | class NextSmallerElementTest { method testFindNextSmallerElements (line 14) | @ParameterizedTest method provideTestCases (line 20) | static Stream provideTestCases() { method testFindNextSmallerElementsExceptions (line 25) | @Test FILE: src/test/java/com/thealgorithms/stacks/PalindromeWithStackTest.java class PalindromeWithStackTest (line 9) | public class PalindromeWithStackTest { method setUp (line 13) | @BeforeEach method testValidOne (line 18) | @Test method testInvalidOne (line 24) | @Test method testValidTwo (line 30) | @Test method testInvalidTwo (line 36) | @Test method testValidThree (line 42) | @Test method testInvalidThree (line 48) | @Test method testBlankString (line 54) | @Test method testStringWithNumbers (line 60) | @Test method testStringWithNumbersTwo (line 66) | @Test method testStringWithNumbersAndLetters (line 72) | @Test FILE: src/test/java/com/thealgorithms/stacks/PostfixEvaluatorTest.java class PostfixEvaluatorTest (line 12) | public class PostfixEvaluatorTest { method testValidExpressions (line 14) | @ParameterizedTest(name = "Expression: \"{0}\" → Result: {1}") method testInvalidExpression (line 21) | @Test method testExtraOperands (line 27) | @Test method testDivisionByZero (line 33) | @Test method testInvalidToken (line 39) | @Test FILE: src/test/java/com/thealgorithms/stacks/PostfixToInfixTest.java class PostfixToInfixTest (line 12) | class PostfixToInfixTest { method testValidPostfixToInfixConversion (line 14) | @ParameterizedTest method provideValidPostfixToInfixTestCases (line 20) | static Stream provideValidPostfixToInfixTestCases() { method testEmptyPostfixExpression (line 24) | @Test method testNullPostfixExpression (line 29) | @Test FILE: src/test/java/com/thealgorithms/stacks/PrefixEvaluatorTest.java class PrefixEvaluatorTest (line 12) | public class PrefixEvaluatorTest { method testValidExpressions (line 14) | @ParameterizedTest(name = "Expression: \"{0}\" → Result: {1}") method testInvalidExpression (line 20) | @Test method testMoreThanOneStackSizeAfterEvaluation (line 26) | @Test FILE: src/test/java/com/thealgorithms/stacks/PrefixToInfixTest.java class PrefixToInfixTest (line 12) | class PrefixToInfixTest { method testValidPrefixToInfixConversion (line 14) | @ParameterizedTest method provideValidPrefixToInfixTestCases (line 20) | static Stream provideValidPrefixToInfixTestCases() { method testEmptyPrefixExpression (line 30) | @Test method testNullPrefixExpression (line 35) | @Test method testMalformedPrefixExpression (line 40) | @Test FILE: src/test/java/com/thealgorithms/stacks/SmallestElementConstantTimeTest.java class SmallestElementConstantTimeTest (line 11) | public class SmallestElementConstantTimeTest { method setSect (line 15) | @BeforeEach method testMinAtFirst (line 20) | @Test method testMinTwo (line 29) | @Test method testNullMin (line 40) | @Test method testBlankHandle (line 49) | @Test method testPushPopAfterEmpty (line 58) | @Test FILE: src/test/java/com/thealgorithms/stacks/SortStackTest.java class SortStackTest (line 10) | public class SortStackTest { method setUp (line 14) | @BeforeEach method testSortEmptyStack (line 19) | @Test method testSortSingleElementStack (line 25) | @Test method testSortAlreadySortedStack (line 33) | @Test method testSortUnsortedStack (line 48) | @Test method testSortWithDuplicateElements (line 63) | @Test method testSortReverseSortedStack (line 78) | @Test method testSortWithAllSameElements (line 96) | @Test method testSortWithNegativeNumbers (line 112) | @Test method testSortWithAllNegativeNumbers (line 130) | @Test method testSortWithZero (line 146) | @Test method testSortLargerStack (line 162) | @Test method testSortTwoElements (line 181) | @Test method testSortTwoElementsAlreadySorted (line 193) | @Test method testSortStackWithMinAndMaxValues (line 205) | @Test method testSortWithManyDuplicates (line 221) | @Test method testOriginalStackIsModified (line 243) | @Test FILE: src/test/java/com/thealgorithms/stacks/StackPostfixNotationTest.java class StackPostfixNotationTest (line 11) | public class StackPostfixNotationTest { method testEvaluate (line 13) | @ParameterizedTest method provideValidTestCases (line 19) | static Stream provideValidTestCases() { method testEvaluateThrowsException (line 23) | @ParameterizedTest method provideInvalidTestCases (line 29) | static Stream provideInvalidTestCases() { FILE: src/test/java/com/thealgorithms/stacks/StackUsingTwoQueuesTest.java class StackUsingTwoQueuesTest (line 11) | public class StackUsingTwoQueuesTest { method setUp (line 15) | @BeforeEach method testPushAndPeek (line 20) | @Test method testPop (line 28) | @Test method testPeek (line 38) | @Test method testIsEmpty (line 47) | @Test method testSize (line 56) | @Test method testPeekEmptyStack (line 66) | @Test FILE: src/test/java/com/thealgorithms/stacks/TrappingRainwaterTest.java class TrappingRainwaterTest (line 7) | public class TrappingRainwaterTest { method testExampleCase (line 9) | @Test method testNoTrapping (line 15) | @Test method testFlatSurface (line 21) | @Test method testSymmetricPit (line 27) | @Test method testSingleBar (line 33) | @Test FILE: src/test/java/com/thealgorithms/stacks/ValidParenthesesTest.java class ValidParenthesesTest (line 8) | class ValidParenthesesTest { method testValidParentheses (line 10) | @Test method testInvalidParentheses (line 18) | @Test method testNullAndOddLength (line 27) | @Test FILE: src/test/java/com/thealgorithms/strings/AhoCorasickTest.java class AhoCorasickTest (line 25) | class AhoCorasickTest { method setUp (line 33) | @BeforeEach method testSearch (line 43) | @Test method testEmptyPatterns (line 54) | @Test method testPatternNotFound (line 65) | @Test method testPatternAtBeginning (line 77) | @Test method testPatternAtEnd (line 89) | @Test method testMultipleOccurrencesOfPattern (line 102) | @Test method testCaseInsensitiveSearch (line 114) | @Test FILE: src/test/java/com/thealgorithms/strings/AlphabeticalTest.java class AlphabeticalTest (line 8) | public class AlphabeticalTest { method testIsAlphabetical (line 10) | @ParameterizedTest(name = "\"{0}\" → Expected: {1}") FILE: src/test/java/com/thealgorithms/strings/AlternativeStringArrangeTest.java class AlternativeStringArrangeTest (line 9) | class AlternativeStringArrangeTest { method provideTestData (line 12) | private static Stream provideTestData() { method arrangeTest (line 18) | @ParameterizedTest(name = "{0} and {1} should return {2}") FILE: src/test/java/com/thealgorithms/strings/AnagramsTest.java class AnagramsTest (line 9) | public class AnagramsTest { method anagramTestData (line 14) | private static Stream anagramTestData() { method testApproach1 (line 20) | @ParameterizedTest method testApproach2 (line 26) | @ParameterizedTest method testApproach3 (line 32) | @ParameterizedTest method testApproach4 (line 38) | @ParameterizedTest method testApproach5 (line 44) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/strings/CharactersSameTest.java class CharactersSameTest (line 8) | class CharactersSameTest { method testIsAllCharactersSame (line 10) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/strings/CheckVowelsTest.java class CheckVowelsTest (line 8) | class CheckVowelsTest { method testHasVowels (line 10) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/strings/CountCharTest.java class CountCharTest (line 10) | class CountCharTest { method testCountCharacters (line 12) | @ParameterizedTest(name = "\"{0}\" should have {1} non-whitespace char... method testCountCharactersNullInput (line 19) | @Test FILE: src/test/java/com/thealgorithms/strings/CountWordsTest.java class CountWordsTest (line 10) | class CountWordsTest { method testWordCount (line 12) | @ParameterizedTest method testSecondaryWordCount (line 18) | @ParameterizedTest method wordCountTestCases (line 24) | private static Stream wordCountTestCases() { method secondaryWordCountTestCases (line 28) | private static Stream secondaryWordCountTestCases() { FILE: src/test/java/com/thealgorithms/strings/HammingDistanceTest.java class HammingDistanceTest (line 13) | class HammingDistanceTest { method testHammingDistance (line 15) | @ParameterizedTest method testHammingDistanceWithNullInputs (line 21) | @ParameterizedTest method provideNullInputs (line 27) | private static Stream provideNullInputs() { method testNotEqualStringLengths (line 31) | @Test FILE: src/test/java/com/thealgorithms/strings/HorspoolSearchTest.java class HorspoolSearchTest (line 8) | class HorspoolSearchTest { method testFindFirstMatch (line 10) | @Test method testFindFirstNotMatch (line 16) | @Test method testFindFirstPatternLongerText (line 22) | @Test method testFindFirstPatternEmpty (line 28) | @Test method testFindFirstTextEmpty (line 34) | @Test method testFindFirstPatternAndTextEmpty (line 40) | @Test method testFindFirstSpecialCharacter (line 46) | @Test method testFindFirstInsensitiveMatch (line 52) | @Test method testFindFirstInsensitiveNotMatch (line 58) | @Test method testGetLastComparisons (line 64) | @Test method testGetLastComparisonsNotMatch (line 71) | @Test method testFindFirstPatternNull (line 78) | @Test method testFindFirstTextNull (line 83) | @Test FILE: src/test/java/com/thealgorithms/strings/IsogramTest.java class IsogramTest (line 13) | public class IsogramTest { method isAlphabeticIsogram (line 18) | private static Stream isAlphabeticIsogram() { method isFullIsogram (line 35) | private static Stream isFullIsogram() { method testIsogramByArray (line 64) | @ParameterizedTest method testIsogramByLength (line 70) | @ParameterizedTest method testNullInputByArray (line 76) | @Test method testNullInputByLength (line 81) | @Test method testEmptyStringByArray (line 86) | @Test method testEmptyStringByLength (line 91) | @Test method testAlphabeticIsogramThrowsException (line 96) | @Test method testFullIsogramWithMixedCharacters (line 107) | @Test FILE: src/test/java/com/thealgorithms/strings/IsomorphicTest.java class IsomorphicTest (line 10) | public final class IsomorphicTest { method testCheckStrings (line 12) | @ParameterizedTest method inputs (line 19) | private static Stream inputs() { FILE: src/test/java/com/thealgorithms/strings/KMPTest.java class KMPTest (line 8) | public class KMPTest { method testNullInputs (line 10) | @Test method testKMPMatcher (line 17) | @Test FILE: src/test/java/com/thealgorithms/strings/KasaiAlgorithmTest.java class KasaiAlgorithmTest (line 8) | public class KasaiAlgorithmTest { method testKasaiBanana (line 10) | @Test method testKasaiAaaa (line 35) | @Test method testKasaiEmptyString (line 49) | @Test method testKasaiSingleChar (line 54) | @Test method testKasaiNullTextOrSuffixArray (line 59) | @Test method testKasaiInvalidSuffixArrayLength (line 65) | @Test method testKasaiInvalidSuffixArrayIndex (line 70) | @Test FILE: src/test/java/com/thealgorithms/strings/LengthOfLastWordTest.java class LengthOfLastWordTest (line 7) | public class LengthOfLastWordTest { method testLengthOfLastWord (line 8) | @Test FILE: src/test/java/com/thealgorithms/strings/LetterCombinationsOfPhoneNumberTest.java class LetterCombinationsOfPhoneNumberTest (line 12) | public class LetterCombinationsOfPhoneNumberTest { method testLetterCombinationsOfPhoneNumber (line 14) | @ParameterizedTest method throwsForWrongInput (line 20) | @ParameterizedTest method provideTestCases (line 26) | private static Stream provideTestCases() { method wrongInputs (line 34) | private static Stream wrongInputs() { FILE: src/test/java/com/thealgorithms/strings/LongestCommonPrefixTest.java class LongestCommonPrefixTest (line 11) | public class LongestCommonPrefixTest { method testLongestCommonPrefix (line 13) | @ParameterizedTest(name = "{index} => input={0}, expected=\"{1}\"") method provideTestCases (line 20) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/strings/LongestNonRepetitiveSubstringTest.java class LongestNonRepetitiveSubstringTest (line 10) | public class LongestNonRepetitiveSubstringTest { method provideTestCases (line 12) | private static Stream provideTestCases() { method testLengthOfLongestSubstring (line 17) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/strings/LongestRepeatedSubstringTest.java class LongestRepeatedSubstringTest (line 11) | class LongestRepeatedSubstringTest { method testLongestRepeatedSubstring (line 13) | @ParameterizedTest(name = "\"{0}\" -> \"{1}\"") method provideTestCases (line 19) | private static Stream provideTestCases() { method testBuildLcpArray (line 23) | @ParameterizedTest(name = "\"{0}\" -> LCP={1}") method provideLcpTestCases (line 30) | private static Stream provideLcpTestCases() { FILE: src/test/java/com/thealgorithms/strings/LowerTest.java class LowerTest (line 7) | public class LowerTest { method toLowerCase (line 8) | @Test FILE: src/test/java/com/thealgorithms/strings/ManacherTest.java class ManacherTest (line 10) | public class ManacherTest { method testLongestPalindrome (line 12) | @ParameterizedTest method provideTestCasesForLongestPalindrome (line 18) | private static Stream provideTestCasesForLongestPalindrome() { method testEmptyAndSingle (line 23) | @ParameterizedTest method provideTestCasesForEmptyAndSingle (line 29) | private static Stream provideTestCasesForEmptyAndSingle() { method testComplexCases (line 33) | @ParameterizedTest method provideTestCasesForComplexCases (line 39) | private static Stream provideTestCasesForComplexCases() { method testSentencePalindromes (line 44) | @ParameterizedTest method provideTestCasesForSentencePalindromes (line 50) | private static Stream provideTestCasesForSentencePalindrome... FILE: src/test/java/com/thealgorithms/strings/MyAtoiTest.java class MyAtoiTest (line 9) | public class MyAtoiTest { method testMyAtoi (line 11) | @ParameterizedTest method testNullInput (line 19) | @Test method testSinglePlus (line 24) | @Test method testSingleMinus (line 29) | @Test method testIntegerMinBoundary (line 34) | @Test method testIntegerMaxBoundary (line 39) | @Test FILE: src/test/java/com/thealgorithms/strings/PalindromeTest.java class PalindromeTest (line 8) | public class PalindromeTest { method provideTestCases (line 9) | private static Stream provideTestCases() { method testPalindrome (line 13) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/strings/PangramTest.java class PangramTest (line 8) | public class PangramTest { method testPangram (line 10) | @Test FILE: src/test/java/com/thealgorithms/strings/PermuteStringTest.java class PermuteStringTest (line 10) | public class PermuteStringTest { method provideTestCases (line 12) | private static Stream provideTestCases() { method testPermutations (line 20) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/strings/RabinKarpTest.java class RabinKarpTest (line 8) | public class RabinKarpTest { method testNullInputs (line 10) | @Test method testHashCollision (line 17) | @Test method testSearchWithCustomQ (line 28) | @Test method testRabinKarpSearch (line 34) | @Test FILE: src/test/java/com/thealgorithms/strings/RemoveDuplicateFromStringTest.java class RemoveDuplicateFromStringTest (line 8) | class RemoveDuplicateFromStringTest { method testEmptyString (line 10) | @Test method testNullString (line 15) | @Test method testSingleCharacterString (line 20) | @Test method testStringWithNoDuplicates (line 25) | @Test method testStringWithDuplicates (line 30) | @Test method testStringWithAllSameCharacters (line 35) | @Test method testStringWithMixedCase (line 40) | @Test FILE: src/test/java/com/thealgorithms/strings/RemoveStarsTest.java class RemoveStarsTest (line 7) | public class RemoveStarsTest { method testExampleCase (line 9) | @Test method testAllStars (line 14) | @Test method testNoStars (line 19) | @Test method testSingleCharacter (line 24) | @Test FILE: src/test/java/com/thealgorithms/strings/ReturnSubsequenceTest.java class ReturnSubsequenceTest (line 10) | class ReturnSubsequenceTest { method testSubsequences (line 12) | @ParameterizedTest method provideTestCases (line 19) | static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/strings/ReverseStringTest.java class ReverseStringTest (line 13) | public class ReverseStringTest { method testCases (line 15) | private static Stream testCases() { method testReverseString (line 20) | @ParameterizedTest method testReverseString2 (line 26) | @ParameterizedTest method testReverseString3 (line 32) | @ParameterizedTest method testReverseStringUsingStack (line 38) | @ParameterizedTest method testReverseStringUsingStackWithNullInput (line 44) | @Test method testReverseStringUsingRecursion (line 49) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/strings/ReverseWordsInStringTest.java class ReverseWordsInStringTest (line 9) | public class ReverseWordsInStringTest { method numberTests (line 10) | @ParameterizedTest method inputStream (line 16) | private static Stream inputStream() { FILE: src/test/java/com/thealgorithms/strings/RotationTest.java class RotationTest (line 7) | public class RotationTest { method testRotation (line 9) | @Test FILE: src/test/java/com/thealgorithms/strings/StringCompressionTest.java class StringCompressionTest (line 8) | public class StringCompressionTest { method stringCompressionTest (line 9) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/strings/StringMatchFiniteAutomataTest.java class StringMatchFiniteAutomataTest (line 11) | class StringMatchFiniteAutomataTest { method searchPattern (line 13) | @ParameterizedTest method provideTestCases (line 19) | private static Stream provideTestCases() { FILE: src/test/java/com/thealgorithms/strings/SuffixArrayTest.java class SuffixArrayTest (line 7) | class SuffixArrayTest { method testEmptyString (line 9) | @Test method testSingleCharacter (line 15) | @Test method testDistinctCharacters (line 21) | @Test method testBananaExample (line 27) | @Test method testStringWithDuplicates (line 33) | @Test method testRandomString (line 39) | @Test FILE: src/test/java/com/thealgorithms/strings/TopKFrequentWordsTest.java class TopKFrequentWordsTest (line 12) | class TopKFrequentWordsTest { method testFindTopKFrequentWords (line 14) | @ParameterizedTest method validTestCases (line 20) | static Stream validTestCases() { method testFindTopKFrequentWordsInvalidInput (line 25) | @ParameterizedTest method invalidTestCases (line 31) | static Stream invalidTestCases() { FILE: src/test/java/com/thealgorithms/strings/UpperTest.java class UpperTest (line 7) | public class UpperTest { method toUpperCase (line 9) | @Test FILE: src/test/java/com/thealgorithms/strings/WordLadderTest.java class WordLadderTest (line 12) | public class WordLadderTest { method testWordLadder (line 23) | @Test method testWordLadder2 (line 38) | @Test method testWordLadder3 (line 53) | @Test method testLadderLength (line 60) | @ParameterizedTest FILE: src/test/java/com/thealgorithms/strings/ZAlgorithmTest.java class ZAlgorithmTest (line 8) | public class ZAlgorithmTest { method testZFunction (line 10) | @Test method testSearchFound (line 16) | @Test method testSearchNotFound (line 21) | @Test FILE: src/test/java/com/thealgorithms/strings/zigZagPattern/ZigZagPatternTest.java class ZigZagPatternTest (line 6) | public class ZigZagPatternTest { method testZigZagPattern (line 8) | @Test FILE: src/test/java/com/thealgorithms/tree/HeavyLightDecompositionTest.java class HeavyLightDecompositionTest (line 9) | class HeavyLightDecompositionTest { method setUp (line 17) | @BeforeEach method testBasicTreeInitialization (line 30) | @Test method testQueryMaxInPath (line 38) | @Test method testUpdateNodeValue (line 47) | @Test method testSkewedTreeMaxQuery (line 56) | @Test method testDepthSwapInPathQuery (line 64) | @Test