实现一个红绿灯
前几天遇到一道有意思的题目。
大意是用 async 和 await 实现一个红绿灯。红灯停 5s、绿灯 10s、黄灯 3s。
扩展:支持手动切换当前灯的状态
前几天遇到一道有意思的题目。
大意是用 async 和 await 实现一个红绿灯。红灯停 5s、绿灯 10s、黄灯 3s。
扩展:支持手动切换当前灯的状态
最近接触了微前端 qiankun,打算玩下,先把用户中心抽离出来,做单独模块;恰好接触到了 RBAC 模型,就写一篇博文记录。
没有任何技术或管理上的进展,能够独立地许诺十年内使生产率、可靠性或简洁性获得数量级上的进步。
There is no single development, in either technology or management technique, which by itselfpromises even one order-of-magnitude improvement within a decade in productivity, in eliability,in simplicity.
硬件提高的性能,很快被软件消耗掉了
– 安迪比尔定理
Andy gives, Bill takes away.
– Andy and Bill’s Law
集成电路上可容纳的晶体管数目,约每隔两年便会增加一倍
– 摩尔定律
number of transistors on a given chip can be doubled every two years
– Moore’s Law
本章的主要身体力行的传授了制作一份文档的细节;流程图的心得;以及探讨了自文档化。
本章严肃的讨论了 里程碑 ,并推荐了一种工具 —— PERT
项目是怎样延迟了整整一年的时间?…一次一天。
How does a project get to be a year late? … One day at a time.
巧匠因为他的工具而出名。
A good workman is known by his tools.
不变只是愿望,变化才是永恒。
SWIFT
普遍的做法是,选择一种方法,试试看;如果失败了,没关系,再试试别的。不管怎么样,重要的是先去尝试。
There is nothing in this world constant but inconstancy.
SWIFT
It is common sense to take a method and try it. If it fails, admit it frankly and try another. Butabove all, try something.