From 042d458d34043d54ae9331864a4c227b62a70355 Mon Sep 17 00:00:00 2001 From: B Karthik <115967163+BKarthik7@users.noreply.github.com> Date: Fri, 4 Oct 2024 23:17:50 +0530 Subject: [PATCH] fix: change location of others to correct places (#5559) --- DIRECTORY.md | 22 +++++++++---------- .../CountSetBits.java | 2 +- .../others/ArrayRightRotation.java | 21 ++++++++++++++++++ .../{others => strings}/CountChar.java | 2 +- .../{others => strings}/CountWords.java | 2 +- .../ReturnSubsequence.java | 2 +- .../StringMatchFiniteAutomata.java | 2 +- .../CountSetBitsTest.java | 2 +- .../{others => strings}/CountCharTest.java | 2 +- .../{others => strings}/CountWordsTest.java | 2 +- .../ReturnSubsequenceTest.java | 2 +- .../StringMatchFiniteAutomataTest.java | 2 +- 12 files changed, 42 insertions(+), 21 deletions(-) rename src/main/java/com/thealgorithms/{others => bitmanipulation}/CountSetBits.java (97%) rename src/{test => main}/java/com/thealgorithms/others/ArrayRightRotation.java (52%) rename src/main/java/com/thealgorithms/{others => strings}/CountChar.java (93%) rename src/main/java/com/thealgorithms/{others => strings}/CountWords.java (97%) rename src/main/java/com/thealgorithms/{others => strings}/ReturnSubsequence.java (97%) rename src/main/java/com/thealgorithms/{others => strings}/StringMatchFiniteAutomata.java (99%) rename src/test/java/com/thealgorithms/{others => bitmanipulation}/CountSetBitsTest.java (90%) rename src/test/java/com/thealgorithms/{others => strings}/CountCharTest.java (96%) rename src/test/java/com/thealgorithms/{others => strings}/CountWordsTest.java (97%) rename src/test/java/com/thealgorithms/{others => strings}/ReturnSubsequenceTest.java (96%) rename src/test/java/com/thealgorithms/{others => strings}/StringMatchFiniteAutomataTest.java (97%) diff --git a/DIRECTORY.md b/DIRECTORY.md index 0b282d8fb..c272d3865 100644 --- a/DIRECTORY.md +++ b/DIRECTORY.md @@ -22,6 +22,7 @@ * [WordSearch](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/backtracking/WordSearch.java) * bitmanipulation * [BitSwap](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/bitmanipulation/BitSwap.java) + * [CountSetBits](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/CountSetBits.java) * [HighestSetBit](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/bitmanipulation/HighestSetBit.java) * [IndexOfRightMostSetBit](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/bitmanipulation/IndexOfRightMostSetBit.java) * [IsEven](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/bitmanipulation/IsEven.java) @@ -409,6 +410,7 @@ * [WordBoggle](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/misc/WordBoggle.java) * others * [ArrayLeftRotation](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/ArrayLeftRotation.java) + * [ArrayRightRotation](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/ArrayRightRotation.java) * [BankersAlgorithm](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/BankersAlgorithm.java) * [BFPRT](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/BFPRT.java) * [BoyerMoore](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/BoyerMoore.java) @@ -416,9 +418,6 @@ * cn * [HammingDistance](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/cn/HammingDistance.java) * [Conway](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/Conway.java) - * [CountChar](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/CountChar.java) - * [CountSetBits](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/CountSetBits.java) - * [CountWords](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/CountWords.java) * [CRC16](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/CRC16.java) * [CRC32](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/CRC32.java) * [CRCAlgorithm](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/CRCAlgorithm.java) @@ -447,11 +446,9 @@ * [PrintAMatrixInSpiralOrder](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/PrintAMatrixInSpiralOrder.java) * [QueueUsingTwoStacks](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/QueueUsingTwoStacks.java) * [RemoveDuplicateFromString](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/RemoveDuplicateFromString.java) - * [ReturnSubsequence](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/ReturnSubsequence.java) * [ReverseStackUsingRecursion](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/ReverseStackUsingRecursion.java) * [RotateMatrixBy90Degrees](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/RotateMatrixBy90Degrees.java) * [SkylineProblem](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/SkylineProblem.java) - * [StringMatchFiniteAutomata](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/StringMatchFiniteAutomata.java) * [Sudoku](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/Sudoku.java) * [TowerOfHanoi](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/TowerOfHanoi.java) * [TwoPointers](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/TwoPointers.java) @@ -562,6 +559,8 @@ * [CharactersSame](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/CharactersSame.java) * [CheckAnagrams](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/CheckAnagrams.java) * [CheckVowels](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/CheckVowels.java) + * [CountChar](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/CountChar.java) + * [CountWords](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/CountWords.java) * [HammingDistance](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/HammingDistance.java) * [HorspoolSearch](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/HorspoolSearch.java) * [Isomorphic](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/Isomorphic.java) @@ -576,11 +575,13 @@ * [Pangram](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/Pangram.java) * [PermuteString](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/PermuteString.java) * [RabinKarp](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/RabinKarp.java) + * [ReturnSubsequence](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/ReturnSubsequence.java) * [ReverseString](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/ReverseString.java) * [ReverseStringRecursive](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/ReverseStringRecursive.java) * [ReverseWordsInString](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/ReverseWordsInString.java) * [Rotation](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/Rotation.java) * [StringCompression](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/StringCompression.java) + * [StringMatchFiniteAutomata](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/others/StringMatchFiniteAutomata.java) * [Upper](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/Upper.java) * [ValidParentheses](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/ValidParentheses.java) * [WordLadder](https://github.com/TheAlgorithms/Java/blob/master/src/main/java/com/thealgorithms/strings/WordLadder.java) @@ -605,6 +606,7 @@ * [WordSearchTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/backtracking/WordSearchTest.java) * bitmanipulation * [BitSwapTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/bitmanipulation/BitSwapTest.java) + * [CountSetBitsTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/CountSetBitsTest.java) * [HighestSetBitTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/bitmanipulation/HighestSetBitTest.java) * [IndexOfRightMostSetBitTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/bitmanipulation/IndexOfRightMostSetBitTest.java) * [IsEvenTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/bitmanipulation/IsEvenTest.java) @@ -875,7 +877,6 @@ * [TwoSumProblemTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/misc/TwoSumProblemTest.java) * others * [ArrayLeftRotationTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/ArrayLeftRotationTest.java) - * [ArrayRightRotation](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/ArrayRightRotation.java) * [ArrayRightRotationTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/ArrayRightRotationTest.java) * [BestFitCPUTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/BestFitCPUTest.java) * [BFPRTTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/BFPRTTest.java) @@ -883,10 +884,7 @@ * cn * [HammingDistanceTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/cn/HammingDistanceTest.java) * [ConwayTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/ConwayTest.java) - * [CountCharTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/CountCharTest.java) * [CountFriendsPairingTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/CountFriendsPairingTest.java) - * [CountSetBitsTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/CountSetBitsTest.java) - * [CountWordsTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/CountWordsTest.java) * [CRC16Test](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/CRC16Test.java) * [CRCAlgorithmTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/CRCAlgorithmTest.java) * [FirstFitCPUTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/FirstFitCPUTest.java) @@ -901,9 +899,7 @@ * [PasswordGenTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/PasswordGenTest.java) * [QueueUsingTwoStacksTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/QueueUsingTwoStacksTest.java) * [RemoveDuplicateFromStringTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/RemoveDuplicateFromStringTest.java) - * [ReturnSubsequenceTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/ReturnSubsequenceTest.java) * [ReverseStackUsingRecursionTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/ReverseStackUsingRecursionTest.java) - * [StringMatchFiniteAutomataTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/StringMatchFiniteAutomataTest.java) * [TestPrintMatrixInSpiralOrder](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/TestPrintMatrixInSpiralOrder.java) * [TwoPointersTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/TwoPointersTest.java) * [WorstFitCPUTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/WorstFitCPUTest.java) @@ -995,6 +991,8 @@ * [CharacterSameTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/CharacterSameTest.java) * [CheckAnagramsTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/CheckAnagramsTest.java) * [CheckVowelsTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/CheckVowelsTest.java) + * [CountCharTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/CountCharTest.java) + * [CountWordsTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/CountWordsTest.java) * [HammingDistanceTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/HammingDistanceTest.java) * [HorspoolSearchTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/HorspoolSearchTest.java) * [IsomorphicTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/IsomorphicTest.java) @@ -1007,11 +1005,13 @@ * [PalindromeTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/PalindromeTest.java) * [PangramTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/PangramTest.java) * [PermuteStringTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/PermuteStringTest.java) + * [ReturnSubsequenceTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/ReturnSubsequenceTest.java) * [ReverseStringRecursiveTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/ReverseStringRecursiveTest.java) * [ReverseStringTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/ReverseStringTest.java) * [ReverseWordsInStringTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/ReverseWordsInStringTest.java) * [RotationTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/RotationTest.java) * [StringCompressionTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/StringCompressionTest.java) + * [StringMatchFiniteAutomataTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/others/StringMatchFiniteAutomataTest.java) * [UpperTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/UpperTest.java) * [ValidParenthesesTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/ValidParenthesesTest.java) * [WordLadderTest](https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/WordLadderTest.java) diff --git a/src/main/java/com/thealgorithms/others/CountSetBits.java b/src/main/java/com/thealgorithms/bitmanipulation/CountSetBits.java similarity index 97% rename from src/main/java/com/thealgorithms/others/CountSetBits.java rename to src/main/java/com/thealgorithms/bitmanipulation/CountSetBits.java index b26f745d4..eb0886e30 100644 --- a/src/main/java/com/thealgorithms/others/CountSetBits.java +++ b/src/main/java/com/thealgorithms/bitmanipulation/CountSetBits.java @@ -1,4 +1,4 @@ -package com.thealgorithms.others; +package com.thealgorithms.bitmanipulation; public class CountSetBits { diff --git a/src/test/java/com/thealgorithms/others/ArrayRightRotation.java b/src/main/java/com/thealgorithms/others/ArrayRightRotation.java similarity index 52% rename from src/test/java/com/thealgorithms/others/ArrayRightRotation.java rename to src/main/java/com/thealgorithms/others/ArrayRightRotation.java index 11e4f4450..125edadb6 100644 --- a/src/test/java/com/thealgorithms/others/ArrayRightRotation.java +++ b/src/main/java/com/thealgorithms/others/ArrayRightRotation.java @@ -1,8 +1,23 @@ package com.thealgorithms.others; +/** + * Provides a method to perform a right rotation on an array. + * A left rotation operation shifts each element of the array + * by a specified number of positions to the right. + * + * https://en.wikipedia.org/wiki/Right_rotation * + */ public final class ArrayRightRotation { private ArrayRightRotation() { } + + /** + * Performs a right rotation on the given array by the specified number of positions. + * + * @param arr the array to be rotated + * @param k the number of positions to rotate the array to the left + * @return a new array containing the elements of the input array rotated to the left + */ public static int[] rotateRight(int[] arr, int k) { if (arr == null || arr.length == 0 || k < 0) { throw new IllegalArgumentException("Invalid input"); @@ -18,6 +33,12 @@ public final class ArrayRightRotation { return arr; } + /** + * Performs reversing of a array + * @param arr the array to be reversed + * @param start starting position + * @param end ending position + */ private static void reverseArray(int[] arr, int start, int end) { while (start < end) { int temp = arr[start]; diff --git a/src/main/java/com/thealgorithms/others/CountChar.java b/src/main/java/com/thealgorithms/strings/CountChar.java similarity index 93% rename from src/main/java/com/thealgorithms/others/CountChar.java rename to src/main/java/com/thealgorithms/strings/CountChar.java index 00cff6860..348905445 100644 --- a/src/main/java/com/thealgorithms/others/CountChar.java +++ b/src/main/java/com/thealgorithms/strings/CountChar.java @@ -1,4 +1,4 @@ -package com.thealgorithms.others; +package com.thealgorithms.strings; public final class CountChar { private CountChar() { diff --git a/src/main/java/com/thealgorithms/others/CountWords.java b/src/main/java/com/thealgorithms/strings/CountWords.java similarity index 97% rename from src/main/java/com/thealgorithms/others/CountWords.java rename to src/main/java/com/thealgorithms/strings/CountWords.java index 515c5d33f..8ab0700f5 100644 --- a/src/main/java/com/thealgorithms/others/CountWords.java +++ b/src/main/java/com/thealgorithms/strings/CountWords.java @@ -1,4 +1,4 @@ -package com.thealgorithms.others; +package com.thealgorithms.strings; /** * @author Marcus diff --git a/src/main/java/com/thealgorithms/others/ReturnSubsequence.java b/src/main/java/com/thealgorithms/strings/ReturnSubsequence.java similarity index 97% rename from src/main/java/com/thealgorithms/others/ReturnSubsequence.java rename to src/main/java/com/thealgorithms/strings/ReturnSubsequence.java index 7ef660ce6..afa8c5f98 100644 --- a/src/main/java/com/thealgorithms/others/ReturnSubsequence.java +++ b/src/main/java/com/thealgorithms/strings/ReturnSubsequence.java @@ -1,4 +1,4 @@ -package com.thealgorithms.others; +package com.thealgorithms.strings; /** * Class for generating all subsequences of a given string. diff --git a/src/main/java/com/thealgorithms/others/StringMatchFiniteAutomata.java b/src/main/java/com/thealgorithms/strings/StringMatchFiniteAutomata.java similarity index 99% rename from src/main/java/com/thealgorithms/others/StringMatchFiniteAutomata.java rename to src/main/java/com/thealgorithms/strings/StringMatchFiniteAutomata.java index 561845f41..719898a1f 100644 --- a/src/main/java/com/thealgorithms/others/StringMatchFiniteAutomata.java +++ b/src/main/java/com/thealgorithms/strings/StringMatchFiniteAutomata.java @@ -1,4 +1,4 @@ -package com.thealgorithms.others; +package com.thealgorithms.strings; import java.util.Set; import java.util.TreeSet; diff --git a/src/test/java/com/thealgorithms/others/CountSetBitsTest.java b/src/test/java/com/thealgorithms/bitmanipulation/CountSetBitsTest.java similarity index 90% rename from src/test/java/com/thealgorithms/others/CountSetBitsTest.java rename to src/test/java/com/thealgorithms/bitmanipulation/CountSetBitsTest.java index ab34c6ba7..412312109 100644 --- a/src/test/java/com/thealgorithms/others/CountSetBitsTest.java +++ b/src/test/java/com/thealgorithms/bitmanipulation/CountSetBitsTest.java @@ -1,4 +1,4 @@ -package com.thealgorithms.others; +package com.thealgorithms.bitmanipulation; import static org.junit.jupiter.api.Assertions.assertEquals; diff --git a/src/test/java/com/thealgorithms/others/CountCharTest.java b/src/test/java/com/thealgorithms/strings/CountCharTest.java similarity index 96% rename from src/test/java/com/thealgorithms/others/CountCharTest.java rename to src/test/java/com/thealgorithms/strings/CountCharTest.java index 2b87d3806..c84f2d01c 100644 --- a/src/test/java/com/thealgorithms/others/CountCharTest.java +++ b/src/test/java/com/thealgorithms/strings/CountCharTest.java @@ -1,4 +1,4 @@ -package com.thealgorithms.others; +package com.thealgorithms.strings; import static org.junit.jupiter.api.Assertions.assertEquals; diff --git a/src/test/java/com/thealgorithms/others/CountWordsTest.java b/src/test/java/com/thealgorithms/strings/CountWordsTest.java similarity index 97% rename from src/test/java/com/thealgorithms/others/CountWordsTest.java rename to src/test/java/com/thealgorithms/strings/CountWordsTest.java index 17bb3aa69..a8aca1ae6 100644 --- a/src/test/java/com/thealgorithms/others/CountWordsTest.java +++ b/src/test/java/com/thealgorithms/strings/CountWordsTest.java @@ -1,4 +1,4 @@ -package com.thealgorithms.others; +package com.thealgorithms.strings; import static org.junit.jupiter.api.Assertions.assertEquals; diff --git a/src/test/java/com/thealgorithms/others/ReturnSubsequenceTest.java b/src/test/java/com/thealgorithms/strings/ReturnSubsequenceTest.java similarity index 96% rename from src/test/java/com/thealgorithms/others/ReturnSubsequenceTest.java rename to src/test/java/com/thealgorithms/strings/ReturnSubsequenceTest.java index 0ae30c48c..d4e1248d0 100644 --- a/src/test/java/com/thealgorithms/others/ReturnSubsequenceTest.java +++ b/src/test/java/com/thealgorithms/strings/ReturnSubsequenceTest.java @@ -1,4 +1,4 @@ -package com.thealgorithms.others; +package com.thealgorithms.strings; import static org.junit.jupiter.api.Assertions.assertArrayEquals; diff --git a/src/test/java/com/thealgorithms/others/StringMatchFiniteAutomataTest.java b/src/test/java/com/thealgorithms/strings/StringMatchFiniteAutomataTest.java similarity index 97% rename from src/test/java/com/thealgorithms/others/StringMatchFiniteAutomataTest.java rename to src/test/java/com/thealgorithms/strings/StringMatchFiniteAutomataTest.java index 6e1947b76..be460c7c4 100644 --- a/src/test/java/com/thealgorithms/others/StringMatchFiniteAutomataTest.java +++ b/src/test/java/com/thealgorithms/strings/StringMatchFiniteAutomataTest.java @@ -1,4 +1,4 @@ -package com.thealgorithms.others; +package com.thealgorithms.strings; import static org.junit.jupiter.api.Assertions.assertEquals;