摘要: 问题 这里有 n 个航班,它们分别从 1 到 n 进行编号。 有一份航班预订表 bookings ,表中第 i 条预订记录 bookings[i] = [firsti, lasti, seatsi] 意味着在从 firsti 到 lasti (包含 firsti 和 lasti )的 每个航班 上预 阅读全文
posted @ 2021-08-16 00:17 tmpUser 阅读(39) 评论(0) 推荐(0) 编辑
摘要: 问题 给定一个正整数数组 A,如果 A 的某个子数组中不同整数的个数恰好为 K,则称 A 的这个连续、不一定不同的子数组为好子数组。 (例如,[1,2,3,1,2] 中有 3 个不同的整数:1,2,以及 3。) 返回 A 中好子数组的数目。 提示: 1 ⇐ A.length ⇐ 20000 1 ⇐ 阅读全文
posted @ 2021-08-16 00:07 tmpUser 阅读(28) 评论(0) 推荐(0) 编辑