摘要: 难度 中等 题目 Leetcode: 设计一个算法,找出数组中最小的k个数。以任意顺序返回这k个数均可。 题目解析这几天返校,就摸鱼几天吧,尬住了 1 class Solution { 2 public: 3 vector<int> smallestK(vector<int>& arr, int k 阅读全文
posted @ 2021-09-03 23:06 伊莉雅碳 阅读(24) 评论(0) 推荐(0)
摘要: 难度 1400 题目 Codeforces: B. Two Buttons time limit per test 2 seconds memory limit per test Vasya has found a strange device. On the front panel of a de 阅读全文
posted @ 2021-09-02 23:56 伊莉雅碳 阅读(43) 评论(0) 推荐(0)
摘要: 难度 中等 题目 Leetcode: 这里有 n 个航班,它们分别从 1 到 n 进行编号。 有一份航班预订表 bookings ,表中第 i 条预订记录 bookings[i] = [firsti, lasti, seatsi] 意味着在从 firsti 到 lasti (包含 firsti 和 阅读全文
posted @ 2021-08-31 21:07 伊莉雅碳 阅读(40) 评论(0) 推荐(0)
摘要: 难度 中等 题目 Leetcode: You are given an array of positive integers w where w[i] describes the weight of ith index (0-indexed). We need to call the functio 阅读全文
posted @ 2021-08-30 23:41 伊莉雅碳 阅读(33) 评论(0) 推荐(0)
摘要: 难度 1400 题目 Codeforces: C. Given Length and Sum of Digits... time limit per test 1 second memory limit per test 256 megabytes You have a positive integ 阅读全文
posted @ 2021-08-28 23:53 伊莉雅碳 阅读(41) 评论(0) 推荐(0)
摘要: 难度 题目 Codeforces: B. Scenes From a Memory time limit per test 1 second memory limit per test 256 megabytes During the hypnosis session, Nicholas sudde 阅读全文
posted @ 2021-08-27 01:00 伊莉雅碳 阅读(107) 评论(0) 推荐(0)
摘要: 难度 中等 题目 Leetcode: All Paths From Source to Target Given a directed acyclic graph (DAG) of n nodes labeled from 0 to n - 1, find all possible paths fr 阅读全文
posted @ 2021-08-25 22:35 伊莉雅碳 阅读(31) 评论(0) 推荐(0)
摘要: 难度 中等 题目 Leetcode: You are playing a simplified PAC-MAN game on an infinite 2-D grid. You start at the point [0, 0], and you are given a destination p 阅读全文
posted @ 2021-08-22 22:07 伊莉雅碳 阅读(31) 评论(0) 推荐(0)
摘要: 难度 1300 题目 Leetcode: D. Make a Power of Two time limit per test 1 second memory limit per test 256 megabytes You are given an integer nn. In 11 move, 阅读全文
posted @ 2021-08-20 23:49 伊莉雅碳 阅读(89) 评论(0) 推荐(0)
摘要: 难度 困难 题目 Leetcode: An attendance record for a student can be represented as a string where each character signifies whether the student was absent, la 阅读全文
posted @ 2021-08-18 22:37 伊莉雅碳 阅读(45) 评论(0) 推荐(0)