ARTS #64 | 善战者无赫赫之功 Algorithm 本周选择的算法题是:Rearrange Words in a Sentence 规则如下: Given a sentence text (A sentence is a string of space-separated words) in the following format: First letter is in upper case. Each... 2020-08-227 min read
更新 CodingTour 最近对个人网站做了一次更新,主要做了这么几件事: 优化 CSS: 支持 Dark Mode 新的 Logo 优化 CSS 现在的这套 CSS 代码自去年建站以来就没怎么动过,文件既没有压缩,还充斥着各种尝试、注释和临时的解决方案。这次想通过对一些工具的使用来指导自己改善代码,我选择了两个工具: Chrome Lighthouse - 对网站生成性能、SEO 等报... 2020-08-214 min read
ARTS #63 | 早就是优势 Algorithm 本周选择的算法题是:Count of Smaller Numbers After Self 规则如下: You are given an integer array nums and you have to return a new counts array. The counts array has the property where counts[i] is ... 2020-08-155 min read
ARTS #62 | 不要只顾低头赶路 Algorithm 本周选择的算法题是:Implement Queue using Stacks 规则如下: Implement the following operations of a queue using stacks. push(x) – Push element x to the back of queue. pop() – Removes the elemen... 2020-08-084 min read
ARTS #61 | 性能优化就是从限制到极致 Algorithm 本周选择的算法题是:Kth Largest Element in an Array 规则如下: Find the kth largest element in an unsorted array. Note that it is the kth largest element in the sorted order, not the kth distinct ele... 2020-08-014 min read
如何系统性的做好高性能优化 “如果你无法衡量它,那么也无法改善它。“ – Lord Kelvin 性能优化就是在各种限制条件下达到极致的过程。 性能测试是优化的前提和基础,也是性能优化结果的检查和度量标准。 性能测试的第一步,先定义性能指标,从客观性能的角度来看,性能指标包括: 响应时间 客户端程序最直观的体现就是卡不卡 服务端程序最直观的体现就是从发出请求到收... 2020-07-292 min read
ARTS #60 Algorithm 本周选择的算法题是: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: hay... 2020-07-257 min read
ARTS #59 Algorithm 本周选择的算法题是:Median of Two Sorted Arrays 规则如下: There are two sorted arrays nums1 and nums2 of size m and n respectively. Find the median of the two sorted arrays. The overall run time co... 2020-07-187 min read
软件架构设计 架构设计能力,因掌握起来困难而显得珍贵。 这是对《软件架构设计》的读后感,看完这本书让我知道:我不是一名合格的架构师。我目前的职责“基础组件的开发和设计”、“已有代码的优化 & 重构”仍然没有跳出开发者的视角,架构师当然也要写代码、了解业务,但不能仅限于此,要深挖产品需求、掌握架构设计的方法、完整的领域知识和技术的实现细节。 从本书描述的架构角色来看,我的职责更侧重于系统... 2020-07-151 min read
ARTS #58 Algorithm 本周选择的算法题是:Goat Latin 规则如下: A sentence S is given, composed of words separated by spaces. Each word consists of lowercase and uppercase letters only. We would like to convert the sente... 2020-07-114 min read