chore: add package level comments
This commit is contained in:
parent
cc87c4b30c
commit
ee1868a10e
303 changed files with 303 additions and 0 deletions
|
|
@ -1,3 +1,4 @@
|
|||
// Package q200 implements a solution for https://leetcode.com/problems/number-of-islands/
|
||||
package q200
|
||||
|
||||
const (
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q201 implements a solution for https://leetcode.com/problems/bitwise-and-of-numbers-range/
|
||||
package q201
|
||||
|
||||
func rangeBitwiseAnd(left int, right int) int {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q202 implements a solution for https://leetcode.com/problems/happy-number/
|
||||
package q202
|
||||
|
||||
type void struct{}
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q205 implements a solution for https://leetcode.com/problems/isomorphic-strings/
|
||||
package q205
|
||||
|
||||
func isIsomorphic(s string, t string) bool {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q206 implements a solution for https://leetcode.com/problems/reverse-linked-list/
|
||||
package q206
|
||||
|
||||
type ListNode struct {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q207 implements a solution for https://leetcode.com/problems/course-schedule/
|
||||
package q207
|
||||
|
||||
func canFinish(numCourses int, prerequisites [][]int) bool {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q208 implements a solution for https://leetcode.com/problems/implement-trie-prefix-tree/
|
||||
package q208
|
||||
|
||||
type tNode struct {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q209 implements a solution for https://leetcode.com/problems/minimum-size-subarray-sum/
|
||||
package q209
|
||||
|
||||
import "math"
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q210 implements a solution for https://leetcode.com/problems/course-schedule-ii/
|
||||
package q210
|
||||
|
||||
func findOrder(numCourses int, prerequisites [][]int) []int {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q211 implements a solution for https://leetcode.com/problems/design-add-and-search-words-data-structure/
|
||||
package q211
|
||||
|
||||
type TrieNode struct {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q212 implements a solution for https://leetcode.com/problems/word-search-ii/
|
||||
package q212
|
||||
|
||||
type TrieNode struct {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q215 implements a solution for https://leetcode.com/problems/kth-largest-element-in-an-array/
|
||||
package q215
|
||||
|
||||
func findKthLargest(nums []int, k int) int {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q216 implements a solution for https://leetcode.com/problems/combination-sum-iii/
|
||||
package q216
|
||||
|
||||
// k numbers sum up to n
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q219 implements a solution for https://leetcode.com/problems/contains-duplicate-ii/
|
||||
package q219
|
||||
|
||||
func containsNearbyDuplicate(nums []int, k int) bool {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q221 implements a solution for https://leetcode.com/problems/maximal-square/
|
||||
package q221
|
||||
|
||||
func maximalSquare(matrix [][]byte) int {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q222 implements a solution for https://leetcode.com/problems/count-complete-tree-nodes/
|
||||
package q222
|
||||
|
||||
type TreeNode struct {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q226 implements a solution for https://leetcode.com/problems/invert-binary-tree/
|
||||
package q226
|
||||
|
||||
type TreeNode struct {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q228 implements a solution for https://leetcode.com/problems/summary-ranges/
|
||||
package q228
|
||||
|
||||
import (
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q230 implements a solution for https://leetcode.com/problems/kth-smallest-element-in-a-bst/
|
||||
package q230
|
||||
|
||||
type TreeNode struct {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q232 implements a solution for https://leetcode.com/problems/implement-queue-using-stacks/
|
||||
package q232
|
||||
|
||||
type MyQueue struct{ data []int }
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q236 implements a solution for https://leetcode.com/problems/lowest-common-ancestor-of-a-binary-tree/
|
||||
package q236
|
||||
|
||||
type TreeNode struct {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q238 implements a solution for https://leetcode.com/problems/product-of-array-except-self/
|
||||
package q238
|
||||
|
||||
func productExceptSelf(nums []int) []int {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q242 implements a solution for https://leetcode.com/problems/valid-anagram/
|
||||
package q242
|
||||
|
||||
func isAnagram(s string, t string) bool {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q283 implements a solution for https://leetcode.com/problems/move-zeroes/
|
||||
package q283
|
||||
|
||||
func moveZeroes(nums []int) {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q289 implements a solution for https://leetcode.com/problems/game-of-life/
|
||||
package q289
|
||||
|
||||
func countLiveNeighbors(board [][]int, row, col int) int {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
// Package q290 implements a solution for https://leetcode.com/problems/word-pattern/
|
||||
package q290
|
||||
|
||||
import "strings"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue