SWE協会(一般社団法人ソフトウェアエンジニアリング協会)推奨フローに従い、新井康平氏選定の LeetCode 69問(通称 arai60)を Python で反復練習するリポジトリ。
- 公式問題リスト: https://1kohei1.com/leetcode/
- LeetCode リスト: https://leetcode.com/list/?selectedList=xt2qzsi5
- 練習会: SWE協会 Discord
1問1ブランチ・1PR・.md ファイルにコードと思考を混ぜて書く。PR は merge せず open のまま、各 attempt を commit で積んでレビューコメントを溜める。
- 自力で解く(5〜10分詰まれば答えを見る)
- LeetCode で AC → ブランチを切って
solutions/<#>-<slug>.mdに attempt を書く - PR を出して Discord
#leetcode_subaru2918で一声かける - レビューコメントが付いたら次の attempt に反映して push
- 3回連続10分以内クリアで master 判定 → PR は close か open のまま放置(merge しない)
ブランチ名: feat/<#>-<slug>(例: feat/206-reverse-linked-list)
ファイル名: solutions/<#>-<slug>.md(例: solutions/206-reverse-linked-list.md)
/arai60でその日のキューを表示(新規1問 + 復習1問)。/arai60 start <slug>で計測開始 → 自力で解く。5〜10分詰まったら答えを見る(粘らない)。- LeetCode で AC →
/arai60 done <slug> <所要分> <ok|ng>。1回目クリア時は自動で/arai60 refsが走り、他者コードがsolutions/<#>-<slug>.mdの references セクションに追記される。 - references を読んで洗練された解法を理解する。
- 次回復習日まで放置 → spaced repetition で自動的にキューに戻る。
/arai60 review で集計確認。詰まりカテゴリを翌週の重点に。
10分以内にエラーなく実装 を 3回連続 クリア → mastered。
| status | 次回復習日 |
|---|---|
untouched |
未着手 |
learning (1回目クリア) |
翌日 |
reviewing (2回連続) |
3日後 |
reviewing (あと1回でmaster) |
7日後 |
mastered |
30日後(劣化チェック) |
| 10分超過 or NG | カウントリセット、翌日に戻す |
進捗管理は tracker.md を見てください。以下は問題への直リンクのみ。
- 206. Reverse Linked List
- 21. Merge Two Sorted Lists
- 141. Linked List Cycle
- 876. Middle of the Linked List
- 143. Reorder List
- 20. Valid Parentheses
- 155. Min Stack
- 150. Evaluate Reverse Polish Notation
- 84. Largest Rectangle in Histogram
- 703. Kth Largest Element in a Stream
- 1046. Last Stone Weight
- 973. K Closest Points to Origin
- 215. Kth Largest Element in an Array
- 621. Task Scheduler
- 355. Design Twitter
- 217. Contains Duplicate
- 242. Valid Anagram
- 1. Two Sum
- 49. Group Anagrams
- 347. Top K Frequent Elements
- 128. Longest Consecutive Sequence
- 200. Number of Islands
- 133. Clone Graph
- 417. Pacific Atlantic Water Flow
- 207. Course Schedule
- 323. Number of Connected Components in an Undirected Graph
- 684. Redundant Connection
- 226. Invert Binary Tree
- 104. Maximum Depth of Binary Tree
- 100. Same Tree
- 102. Binary Tree Level Order Traversal
- 572. Subtree of Another Tree
- 105. Construct Binary Tree from Preorder and Inorder Traversal
- 98. Validate Binary Search Tree
- 230. Kth Smallest Element in a BST
- 235. Lowest Common Ancestor of a BST
- 124. Binary Tree Maximum Path Sum
- 297. Serialize and Deserialize Binary Tree
- 70. Climbing Stairs
- 198. House Robber
- 213. House Robber II
- 91. Decode Ways
- 322. Coin Change
- 152. Maximum Product Subarray
- 139. Word Break
- 300. Longest Increasing Subsequence
- 416. Partition Equal Subset Sum
- 153. Find Minimum in Rotated Sorted Array
- 33. Search in Rotated Sorted Array
- 4. Median of Two Sorted Arrays
- 121. Best Time to Buy and Sell Stock
- 3. Longest Substring Without Repeating Characters
- 424. Longest Repeating Character Replacement
- 76. Minimum Window Substring
- 125. Valid Palindrome
- 167. Two Sum II - Input Array Is Sorted
- 15. 3Sum
- 11. Container With Most Water
- 42. Trapping Rain Water
leetcode-arai60/
├── README.md # このファイル
├── tracker.md # 全問題の進捗テーブル(single source of truth)
├── queue.md # 今日のキュー(コマンドが生成、.gitignore対象)
├── log/YYYY-MM-DD.md # 日次ログ(.gitignore対象)
└── solutions/<#>-<slug>.md # 実装 + 思考 + references + notes
# <#>. <問題名>
<LeetCode URL>
カテゴリ: <category>
---
## attempt 1 (YYYY-MM-DD, NN min, ok|ng)
最初に考えたこと:
- ...
\`\`\`python
def solve():
...
\`\`\`
詰まった点・気づき:
- ...
---
## attempt 2 (YYYY-MM-DD, NN min, ok|ng)
ref1 を読んで気づいた:
- ...
\`\`\`python
def solve():
...
\`\`\`
---
## references
- ref1: LeetCode Editorial — <approach>
\`\`\`python
...
\`\`\`
- ref2: neetcode — <approach>
- ref3: Python標準ライブラリ活用 (<library>)
## notes
- 学んだこと・パターンgit checkout -b feat/206-reverse-linked-list
# solutions/206-reverse-linked-list.md に attempt 1 を書く
git add solutions/206-reverse-linked-list.md
git commit -m "206 reverse-linked-list: attempt 1"
git push -u origin feat/206-reverse-linked-list
gh pr create --fillPR 本文は LeetCode URL 1行のみで OK(hayashi-ay 流)。
| コマンド | 用途 |
|---|---|
/arai60 / /arai60 today |
今日のキュー表示・生成 |
/arai60 start <slug> |
計測開始、solutions/<#>-<slug>.md テンプレ作成 |
/arai60 done <slug> [<分>] [<ok|ng>] |
attempt 記録。引数省略で LeetCode AC カウンタ差分から自動判定 |
/arai60 refs <slug> |
他者コード取得(手動再実行用) |
/arai60 review |
週次集計 |