Skip to content

Commit 3dcbbe0

Browse files
xzhsehyanglbme
authored andcommitted
chore: format code with clang-format
1 parent d11fa4c commit 3dcbbe0

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

solution/0300-0399/0331.Verify Preorder Serialization of a Binary Tree/Solution.java

+2-4
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,8 @@ public boolean isValidSerialization(String preorder) {
33
List<String> stk = new ArrayList<>();
44
for (String s : preorder.split(",")) {
55
stk.add(s);
6-
while (stk.size() >= 3
7-
&& stk.get(stk.size() - 1).equals("#")
8-
&& stk.get(stk.size() - 2).equals("#")
9-
&& !stk.get(stk.size() - 3).equals("#")) {
6+
while (stk.size() >= 3 && stk.get(stk.size() - 1).equals("#")
7+
&& stk.get(stk.size() - 2).equals("#") && !stk.get(stk.size() - 3).equals("#")) {
108
stk.remove(stk.size() - 1);
119
stk.remove(stk.size() - 1);
1210
stk.remove(stk.size() - 1);

solution/0300-0399/0351.Android Unlock Patterns/Solution.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ class Solution {
2929
vis[i] = false;
3030
return ans;
3131
};
32-
32+
3333
return dfs(1, 1) * 4 + dfs(2, 1) * 4 + dfs(5, 1);
3434
}
3535
};

0 commit comments

Comments
 (0)