t705

package
v0.0.0-...-bddcb22 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 16, 2025 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MyHashSet

type MyHashSet struct {
	// contains filtered or unexported fields
}

MyHashSet 705.设计哈希集合 https://leetcode.cn/problems/design-hashset

func Constructor

func Constructor() MyHashSet

func (*MyHashSet) Add

func (s *MyHashSet) Add(key int)

func (*MyHashSet) Contains

func (s *MyHashSet) Contains(key int) bool

Contains 根据 key 找到对应的链表,遍历链表,返回 key 是否存在

func (*MyHashSet) Remove

func (s *MyHashSet) Remove(key int)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL