摘要:
In a given integer array nums, there is always exactly one largest element. Find whether the largest element in the array is at least twice as much as 阅读全文
摘要:
ls命令用来显示目标列表,在Linux中是使用率较高的命令。ls命令的输出信息可以进行彩色加亮显示,以分区不同类型的文件。 阅读全文
摘要:
Reverse a singly linked list. 反转单链表 C++(9ms): 迭代 阅读全文
摘要:
Given a binary search tree with non-negative values, find the minimum absolute difference between values of any two nodes. Example: Note: There are at 阅读全文
摘要:
Given a list of sorted characters letters containing only lowercase letters, and given a target letter target, find the smallest element in the list t 阅读全文
摘要:
You are given two arrays (without duplicates) nums1 and nums2 where nums1’s elements are subset of nums2. Find all the next greater numbers for nums1' 阅读全文
摘要:
Given a binary search tree and the lowest and highest boundaries as L and R, trim the tree so that all its elements lies in [L, R] (R >= L). You might 阅读全文
摘要:
cd命令用来切换工作目录至dirname。 其中dirName表示法可为绝对路径或相对路径。若目录名称省略,则变换至使用者的home directory(也就是刚login时所在的目录)。 另外,~也表示为home directory的意思,.则是表示目前所在的目录,..则表示目前目录位置的上一层目 阅读全文
摘要:
nl命令读取 file 参数(缺省情况下标准输入),计算输入中的行号,将计算过的行号写入标准输出。在输出中,nl命令根据您在命令行中指定的标志来计算左边的行。 输入文本必须写在逻辑页中。每个逻辑页有头、主体和页脚节(可以有空节)。除非使用-p选项,nl 命令在每个逻辑页开始的地方重新设置行号。可以单 阅读全文
摘要:
Given a binary tree, return the tilt of the whole tree. The tilt of a tree node is defined as the absolute difference between the sum of all left subt 阅读全文