2 张平

学生身份

我要认证

目前就读于武汉大学经管。 希望探索文理结合的自由之路。

等级
TA的排名 1w+

LeetCode C++ 832. Flipping an Image【Array】简单

Given a binary matrix A , we want to flip the image horizontally, then invert it, and return the resulting image.To flip an image horizontally means that each row of the image is reversed. For example, flipping [1, 1, 0] horizontally results in [0, 1, 1]

2020-08-03 15:08:04

LeetCode C++ 429. N-ary Tree Level Order Traversal【Tree/BFS/DFS】中等

Given an n-ary tree, return the level order traversal of its nodes’ values.Nary-Tree input serialization is represented in their level order traversal, each group of children is separated by the null value (See examples).Example 1:Input: root = [1,null

2020-08-03 14:38:33

LeetCode C++ 415. Add Strings【String】简单

Given two non-negative integers num1 and num2 represented as string, return the sum of num1 and num2 .Note:The length of both num1 and num2 is < 5100 .Both num1 and num2 contains only digits 0-9 .Both num1 and num2 does not contain any leading zero

2020-08-03 11:30:56

LeetCode C++ 114. Flatten Binary Tree to Linked List【Tree/DFS】中等

Given a binary tree, flatten it to a linked list in-place.For example, given the following tree: 1 / \ 2 5 / \ \3 4 6The flattened tree should look like:1 \ 2 \ 3 \ 4 \ 5 \ 6题意

2020-08-03 01:25:06

LeetCode C++ 面试题 01.02. Check Permutation LCCI

Given two strings,write a method to decide if one is a permutation of the other.Example 1:Input: s1 = "abc", s2 = "bca"Output: trueExample 2:Input: s1 = "abc", s2 = "bad"Output: falseNote:0 <= len(s1) <= 1000 <= len(s2) <= 100题目:判

2020-07-29 17:14:11

LeetCode C++ 792. Number of Matching Subsequences【动态规划】中等

Given string S and a dictionary of words words , find the number of words[i] that is a subsequence of S .Example:Input: S = "abcde"words = ["a", "bb", "acd", "ace"]Output: 3Explanation: There are three words in words that are a subsequence of S: "a",

2020-07-29 00:48:35

LeetCode C++ 392. Is Subsequence【动态规划】简单

Given a string s and a string t , check if s is subsequence of t .A subsequence of a string is a new string which is formed from the original string by deleting some (can be none) of the characters without disturbing the relative positions of the remainin

2020-07-29 00:37:24

LeetCode C++ 面试题 01.01. Is Unique LCCI【Array】简单

Implement an algorithm to determine if a string has all unique characters. What if you cannot use additional data structures?Example 1:Input: s = "leetcode"Output: falseExample 2:Input: s = "abc"Output: trueNote: 如果你不使用额外的数据结构,会很加分。题意:实现一个算法,确认一个

2020-07-28 22:38:15

LeetCode C++ 28. Implement strStr()【字符串】简单

Implement strStr() .Return the index of the first occurrence of needle in haystack, or -1 if needle is not part of haystack.Example 1:Input: haystack = "hello", needle = "ll"Output: 2Example 2:Input: haystack = "aaaaa", needle = "bba"Output: -1C

2020-07-28 17:59:33

LeetCode C++ 709. To Lower Case【字符串】简单

Implement function ToLowerCase() that has a string parameter str, and returns the same string in lowercase.Example 1:Input: "Hello"Output: "hello"Example 2:Input: "here"Output: "here"Example 3:Input: "LOVELY"Output: "lovely"题意:将字符串中的大写字母转为小写。

2020-07-28 12:00:49

LeetCode C++ 151. Reverse Words in a String 【字符串】中等·

Given an input string, reverse the string word by word.Example 1:Input: "the sky is blue"Output: "blue is sky the"Example 2:Input: " hello world! "Output: "world! hello"Explanation: Your reversed string should not contain leading or trailing spac

2020-07-28 11:42:33

LeetCode C++ 559. Maximum Depth of N-ary Tree【Tree/DFS/BFS】简单

Given a n-ary tree, find its maximum depth.The maximum depth is the number of nodes along the longest path from the root node down to the farthest leaf node.Nary-Tree input serialization is represented in their level order traversal, each group of childr

2020-07-28 01:13:10

LeetCode C++ 104. Maximum Depth of Binary Tree【Tree/DFS/BFS】简单

Given a binary tree, find its maximum depth.The maximum depth is the number of nodes along the longest path from the root node down to the farthest leaf node.Note: A leaf is a node with no children.Example:Given binary tree [3,9,20,null,null,15,7],

2020-07-28 00:52:00

【Makefile】学习笔记1 Makefile文件、规则、工作流程、变量定义和自动化变量

文章目录1. `Makefile` 文件概述2. `Makefile` 文件中包含哪些规则?3. `Makefile` 的工作流程4. `Makefile` 通配符的使用5. `Makefile` 变量的定义和使用(1) 变量的定义(2) 变量的基本赋值① 简单赋值② 递归赋值③ 条件赋值④ 追加赋值6. `Makefile` 自动化变量`Makefile` 目标文件搜索(VPATH和vpath)`Makefile` 路径搜索使用案例9. `Makefile` 隐含规则10. `Makefile` ifeq

2020-07-27 21:45:45

LeetCode C++ 1025. Divisor Game【数学/动态规划】简单

Alice and Bob take turns playing a game, with Alice starting first.Initially, there is a number N on the chalkboard. On each player’s turn, that player makes a move consisting of:Choosing any x with 0 < x < N and N % x == 0 .Replacing the number

2020-07-25 18:27:16

【算法学习】图论1 图的概念和存储

文章目录1. 邻接矩阵2. 邻接表3. 链式前向星图 Graph 是图论中的基本研究对象,由顶点 Vertex 和边 Edge 组成。1. 邻接矩阵2. 邻接表3. 链式前向星用数组模拟链表,这种方法叫做

2020-07-25 16:07:52

LintCode C++ 1740. Online Stock Span【单调栈/队列】中等

Write a class StockSpanner which collects daily price quotes for some stock, and returns the span of that stock’s price for the current day.The span of the stock’s price today is defined as the maximum number of consecutive days (starting from today and g

2020-07-24 22:35:55

【操作系统】Oranges学习笔记(二) 第三章2 保护模式进阶

文章目录3.2 保护模式进阶1. 体会超过1MB内存的访问2. 从保护模式到实模式3. LDT(Local Descriptor Table)d 学习调用门,无特权级转移4. 特权级概述4.1 CPL、DPL、RPL5. 特权级转移6. 关于“保护”的思考第三章:保护模式下的中断和异常第三章:小结第三章:a 为什么需要认识IA32架构IntelCPU保护模式高云朋 2018-07-29 16:18:09 86 收藏分类专栏: orang’s 于渊著版权第三章主要是讲IA32架构IntelCPU

2020-07-24 14:52:39

【操作系统】Oranges学习笔记(二) 第三章5 保护模式下的I/O和小结

文章目录3.5 保护模式下的I/O1. IOPL2. I/O许可位图(I/O Permission Bitmap)3.6 保护模式小结3.5 保护模式下的I/O对IO的控制权限很重要,保护模式对此也做了限制。如果用户进程不被许可,就无法进行IO操作。限制通过两方面进行——IOPL和I/O许可位图。1. IOPLIOPL是I/O保护机制的关键之一,位于 eflags 的 12,13 位:I/O敏感指令 I/O Sensitive Instructions 如 in, ins, out, outs

2020-07-24 14:48:15

【操作系统】Oranges学习笔记(二) 第三章4 保护模式下的中断和异常

文章目录3.4 保护模式下的中断和异常1. 中断和异常机制2. 外部中断3. 设置和编程操作8259A4. 建立IDT5. 实现一个中断6. 时钟中断试验7. 几点额外说明(1) 特权级变换(2) 中断或异常发生时的堆栈变化(3) 中断门和陷阱门的区别3.4 保护模式下的中断和异常以前,我们使用中断都是在实模式下进行的,如 int 15h 得到内存信息后在保护模式下把它们显示出来。原因在于,在保护模式下,中断机制发生了很大变化。保护模式下,原来的中断向量表已经被IDT所代替,实模式下能用的BIOS中

2020-07-24 14:45:51

查看更多

勋章 我的勋章
  • 签到新秀
    签到新秀
    累计签到获取,不积跬步,无以至千里,继续坚持!
  • 新人勋章
    新人勋章
    用户发布第一条blink获赞超过3个即可获得
  • 阅读者勋章Lv1
    阅读者勋章Lv1
    授予在CSDN APP累计阅读博文达到3天的你,是你的坚持与努力,使你超越了昨天的自己。
  • 持之以恒
    持之以恒
    授予每个自然月内发布4篇或4篇以上原创或翻译IT博文的用户。不积跬步无以至千里,不积小流无以成江海,程序人生的精彩需要坚持不懈地积累!
  • 勤写标兵Lv4
    勤写标兵Lv4
    授予每个自然周发布9篇以上(包括9篇)原创IT博文的用户。本勋章将于次周周三上午根据用户上周的博文发布情况由系统自动颁发。