首页
AI Coding
NEW
沸点
课程
直播
活动
AI刷题
APP
插件
搜索历史
清空
创作者中心
写文章
发沸点
写笔记
写代码
草稿箱
创作灵感
查看更多
会员
登录
注册
力扣算法题
Warson_L
创建于2022-02-20
订阅专栏
力扣算法题
暂无订阅
共25篇文章
创建于2022-02-20
订阅专栏
默认顺序
默认顺序
最早发布
最新发布
找到第n个完美数
在做CS106B课程作业时,有一个函数是计算第n个完美数,当时就觉得恶心。 经过百度后才知道有个科学家证明了如何快速识别一个数是否是完美数。
704. Binary Search
Given an array of integers nums which is sorted in ascending order, and an integer target, write a f
1029. Two City Scheduling
A company is planning to interview 2n people. Given the array costs where costs[i] = [aCosti, bCosti
881. Boats to Save People
You are given an array people where people[i] is the weight of the ith person, and an infinite numbe
1663. Smallest String With A Given Numeric Value
The numeric value of a lowercase character is defined as its position (1-indexed) in the alphabet, s
763. Partition Labels
You are given a string s. We want to partition the string into as many parts as possible so that eac
1007. Minimum Domino Rotations For Equal Row
In a row of dominoes, tops[i] and bottoms[i] represent the top and bottom halves of the ith domino.
895. Maximum Frequency Stack
Design a stack-like data structure to push elements to the stack and pop the most frequent element f
316. Remove Duplicate Letters
Given a string s, remove duplicate letters so that every letter appears once and only once. You must
856. Score of Parentheses
Medium Given a balanced parentheses string s, return the score of the string. The score of a balance
2. Add Two Numbers
You are given two non-empty linked lists representing two non-negative integers. The digits are stor
1359. Count All Valid Pickup and Delivery Options
Count All Valid Pickup and Delivery Options Hard Given n orders, each order consist in pickup and de
740. Delete and Earn
You are given an integer array nums. You want to maximize the number of points you get by performing
799. Champagne Tower
We stack glasses in a pyramid, where the first row has 1 glass, the second row has 2 glasses, and so
413. Arithmetic Slices
An integer array is called arithmetic if it consists of at least three elements and if the differenc
392. Is Subsequence
Given two strings s and t, return true if s is a subsequence of t , or false otherwise. A subsequenc
338. Counting Bits
Given an integer n, return an array ans of length n + 1 such that for each i **(0 <= i <= n) , ans[i
228. Summary Ranges
Summary Ranges Easy You are given a sorted unique integer array nums. Return the smallest sorted lis
662. Maximum Width of Binary Tree
Given the root of a binary tree, return the maximum width of the given tree. The maximum width of a
0001. 力扣算法题分类
广度搜索 847. Shortest Path Visiting All 图 847. Shortest Path Visiting All
下一页