08 2019 档案
摘要:Description e Tribonacci sequence Tn is defined as follows: T0 = 0, T1 = 1, T2 = 1, and Tn+3 = Tn + Tn+1 + Tn+2 for n = 0. Given , return the value of
阅读全文
摘要:key value 通过key获取或设置value SET key value GET key : SET if not exists : +1 原子操作 给key设置过期时间 获取一个key的存活时间,每次set一个key的value,过期时间将会重置 已过期 永不过期 list 插入数据到lis
阅读全文
摘要:Description Given a sorted (in ascending order) integer array of elements and a value, write a function to search in . If exists, then return its inde
阅读全文
摘要:Description You are given a license key represented as a string S which consists only alphanumeric character and dashes. The string is separated into
阅读全文
摘要:Description Given a valid (IPv4) IP , return a defanged version of that IP address. A defanged IP address replaces every period with . Example 1: Exam
阅读全文
摘要:Description Implement function ToLowerCase() that has a string parameter str, and returns the same string in lowercase. Example 1: Example 2: Example
阅读全文
摘要:Description Given an array of size $n$, find the majority element. The majority element is the element that appears more than times. You may assume th
阅读全文
摘要:Description 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 th
阅读全文