此博客链接: 合并区间 题目链接:https://leetcode-cn.com/leetbook/read/array-and-string/c5tv3/ 题目 以数组 intervals 表示若干个区间的集合,其中单个区间为 intervals[i] = [starti, endi] 。请你合并 ...
分类:
其他好文 时间:
2021-06-02 19:33:10
阅读次数:
0
https://github.com/victronenergy/QsLog https://github.com/mkroening/qslog QsLog - the simple Qt logger QsLog is an easy to use logger that is based on ...
分类:
其他好文 时间:
2021-06-02 19:08:35
阅读次数:
0
第一轮刷题解法: 1)如果长度为1,返回第一个字符串;如果存在空,返回空;否则长度递增,逐一比较,有不同则返回当前前缀。 class Solution: def longestCommonPrefix(self, strs: List[str]) -> str: count_prefix = 1 i ...
分类:
编程语言 时间:
2021-06-02 19:01:16
阅读次数:
0
Leetcode 第243场周赛 前两题简单。 第三题一个模拟,容易边界处理不好。 第四题dp,卡精度。 第一题 https://leetcode-cn.com/problems/check-if-word-equals-summation-of-two-words/ 直接算就行。 class So ...
分类:
其他好文 时间:
2021-06-02 18:17:06
阅读次数:
0
JAVA 暴力(BFS): public final int[] findBall(int[][] grid) { int len = grid[0].length; int[] balls = new int[len]; for (int i = 0; i < balls.length; i++) ...
分类:
其他好文 时间:
2021-06-02 18:14:01
阅读次数:
0
227. 基本计算器 II Difficulty: ** 示例 1: 输入:s = "3+22" 输出:7 示例 2: 输入:s = " 3/2 " 输出:1 示例 3: 输入:s = " 3+5 / 2 " 输出:5 提示: 1 ? s.length ? 3 * 105 s 由整数和算符 ('+' ...
分类:
其他好文 时间:
2021-06-02 17:24:20
阅读次数:
0
题目 package whale.leetcode.simple; /** * @Author: WhaleFall541 * @Date: 2021/5/29 20:30 */ public class AddTwoSumLinkedList { public static class ListN ...
分类:
其他好文 时间:
2021-06-02 16:21:23
阅读次数:
0
160. 相交链表 Difficulty: 简单 编写一个程序,找到两个单链表相交的起始节点。 如下面的两个链表**:** 在节点 c1 开始相交。 示例 1: 输入:intersectVal = 8, listA = [4,1,8,4,5], listB = [5,0,1,8,4,5], skip ...
分类:
其他好文 时间:
2021-06-02 16:01:26
阅读次数:
0
https://leetcode-cn.com/problems/construct-binary-tree-from-inorder-and-postorder-traversal/ 根据一棵树的中序遍历与后序遍历构造二叉树。 注意: 你可以假设树中没有重复的元素。 例如,给出 中序遍历 inor ...
分类:
其他好文 时间:
2021-06-02 15:25:05
阅读次数:
0
简介 忘不了, 这是华为面试官给我的面试题, 但是我没有在1分钟内做出来. 或许那个时候面试官本来就不想要一个人. 使用模拟的方法. 使用一个visited数组, 判断是否走到边界, 只有四个方向: j++ i++ j-- i-- 依次循环. code class Solution { public ...
分类:
编程语言 时间:
2021-06-02 14:55:47
阅读次数:
0