ARTS #122 Algorithm 本周选择的算法题是:Break a Palindrome。 规则 Given a palindromic string of lowercase English letters palindrome, replace exactly one character with any lowercase English letter so that the resulti...
ARTS #121 Algorithm 本周选择的算法题是:Sudoku Solver。 规则 Write a program to solve a Sudoku puzzle by filling the empty cells. A sudoku solution must satisfy all of the following rules: Each of the digits 1-9 ...
2021 Q3 阅读记录 这个季度读了三本书: 重新定义团队,阅读笔记见: Google 工作法 估值的标尺 计算机是怎样跑起来的,阅读笔记见: ARTS #120 其中两本写过简短的阅读笔记了。《估值的标尺》也是一本特别务实的书,我很喜欢这一段: 这个世界上每一座山川,每一片星云,每一个凡人都与众不同。人生是一个人的旅行,再平凡也是“限量版”。不管经历了怎样的风吹雨打,不管走了多少里山路...
ARTS #120 Algorithm 本周选择的算法题是:Majority Element。 规则 Given an array nums of size n, return the majority element. The majority element is the element that appears more than ⌊n / 2⌋ times. You may assume tha...
ARTS #119 Algorithm 本周选择的算法题是:Word Break。 规则 Given a string s and a dictionary of strings wordDict, return true if s can be segmented into a space-separated sequence of one or more dictionary words. Note...
ARTS #118 Algorithm 本周选择的算法题是:Contains Duplicate。 规则 Given an integer array nums, return true if any value appears at least twice in the array, and return false if every element is distinct. Example 1: ...
ARTS #117 Algorithm 本周选择的算法题是:Target Sum。 规则 You are given an integer array nums and an integer target. You want to build an expression out of nums by adding one of the symbols '+' and '-' before each in...
Google 工作法 《重新定义团队》 Google 的人才密度很高,这其中很大原因要归结为对招聘环节的重视。优秀候选人在公司、行业里有不错的位置,各个行业绝大多数的顶尖人才并没有在找工作,通过一般的招聘渠道很难找到好的候选人。Google 采用了主动出击的方式,如员工内推、行业搜寻等,就算用人需求很大,在竞争激烈的市场环境下也没有为了短期利益损害长期以来坚持的价值观。 Google 需要的人有两个特点: ...
ARTS #116 Algorithm 本周选择的算法题是:Implement Trie (Prefix Tree)。 规则 A trie (pronounced as “try”) or prefix tree is a tree data structure used to efficiently store and retrieve keys in a dataset of strings. The...
ARTS #115 Algorithm 本周选择的算法题是:Decode Ways。 规则 A message containing letters from A-Z can be encoded into numbers using the following mapping: 'A' -> "1" 'B' -> "2" ... 'Z' -> "26" To decode an ...