Open
Conversation
n6o
commented
Feb 3, 2026
| return false | ||
| } | ||
|
|
||
| if openToClose[openBrackets[l-1]] != r { |
Owner
Author
There was a problem hiding this comment.
変数で宣言した方が理解しやすいとStep2で思ったが、書き下すときにはできてなかったことにPR作成後に気づきました
lastOpenBracket := openBrackets[l-1]
nodchip
reviewed
Feb 4, 2026
| openBrackets := make([]byte, 0, len(s)) | ||
|
|
||
| for i := 0; i < len(s); i++ { | ||
| if ob, found := closeBracketPair[s[i]]; found { |
There was a problem hiding this comment.
ob が何の略か、すぐには分かりませんでした。こちらのコメントをご参照ください。
hemispherium/LeetCode_Arai60#10 (comment)
Owner
Author
There was a problem hiding this comment.
ありがとうございます。
英単語から文字を削って識別子にすると、読み手の認知負荷が上がる場合があります。原則としてフルスペルで記述することをお勧めします。
今後は原則フルスペルで記述するようにします。
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
今回の問題
Valid Parentheses - LeetCode
使用言語
Go
次に解く問題
Reverse Linked List - LeetCode