摘要: 地址:https://leetcode-cn.com/problems/contains-duplicate-ii/ <?php /** 给定一个整数数组和一个整数 k,判断数组中是否存在两个不同的索引 i 和 j,使得 nums [i] = nums [j],并且 i 和 j 的差的 绝对值 至多 阅读全文
posted @ 2020-04-16 18:24 花花妹子。 阅读(97) 评论(0) 推荐(0) 编辑
摘要: 地址:https://leetcode-cn.com/problems/contains-duplicate/ <?php /** 给定一个整数数组,判断是否存在重复元素。 如果任意一值在数组中出现至少两次,函数返回 true 。如果数组中每个元素都不相同,则返回 false 。 示例 1: 输入: 阅读全文
posted @ 2020-04-16 18:10 花花妹子。 阅读(156) 评论(0) 推荐(0) 编辑