mirror of
https://github.com/TheAlgorithms/Java.git
synced 2025-12-19 07:00:35 +08:00
style: enabled InnerAssignment in checkstyle (#5162)
* style: enabled InnerAssignment in checkstyle * Refactor code formatting in KnapsackMemoization.java and UnionFind.java * style: remove redundant blank line * style: mark `includeCurrentItem` and `excludeCurrentItem` as `final` * style: remove `KnapsackMemoization` from `pmd-exclude.properties` * style: use `final` --------- Co-authored-by: Piotr Idzik <65706193+vil02@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
f8e62fbb90
commit
0f42e995a4
@@ -34,7 +34,8 @@ public final class LongestAlternatingSubsequence {
|
||||
int[][] las = new int[n][2]; // las = LongestAlternatingSubsequence
|
||||
|
||||
for (int i = 0; i < n; i++) {
|
||||
las[i][0] = las[i][1] = 1;
|
||||
las[i][0] = 1;
|
||||
las[i][1] = 1;
|
||||
}
|
||||
|
||||
int result = 1; // Initialize result
|
||||
|
||||
Reference in New Issue
Block a user