> 2021年11月30日信息消化 ### Paradoxes of Life origin: [Paradoxes of Life](https://sahilbloom.substack.com/p/paradoxes-of-life-1c5?token=eyJ1c2VyX2lkIjoxODU4NjU0MiwicG9zdF9pZCI6NDQzODIyMjEsIl8iOiJhVEc1TiIsImlhdCI6MTYzNzgwMzY1NSwiZXhwIjoxNjM3ODA3MjU1LCJpc3MiOiJwdWItNjYyNDQiLCJzdWIiOiJwb3N0LXJlYWN0aW9uIn0.c4A74K1iJQ5P0c3NeE9OQJ9JKqGSIXgJKiQnWoCdjzA) ##### Today at a Glance: - A paradox is defined as a seemingly **absurd** or **self-contradictory** statement or proposition that when investigated or explained may prove to be well founded or true. 悖论被定义为看似荒谬或自相矛盾的陈述或命题,经过调查或解释,可能证明是有根据的或真实的。 - Life is full of paradoxes. Once you become aware of them, you will find yourself empowered to use them to your advantage. 生活充满了悖论。一旦你意识到它们,你就会发现自己有能力利用它们为你所用。 #### Paradoxes of Life - The Persuasion Paradox - The most persuasive people don’t argue—they observe, listen, and ask questions. **Argue less, persuade more.** Persuasion is an art that requires a paintbrush, not a sledgehammer. - The Effort Paradox - Sprezzatura is an Italian word meaning “studied carelessness”—it encapsulates the effortful art of appearing effortless. **You have to put in more effort to make something appear effortless.** Effortless, elegant performances are often the result of a large volume of effortful, gritty practice. Watch videos of Roger Federer playing tennis in his prime. There is a certain nonchalance to his actions on the court, but this nonchalance was the earned result of endless hours of studied, careful, meticulous practice. Small things become big things. Simple is not simple. - The Wisdom Paradox - “The more I learn, the more I realize how much I don't know.” — Albert Einstein **The more you learn, the more you are exposed to the immense unknown.** This should be empowering, not frightening. Embrace your own ignorance. Embrace lifelong learning. - The Productivity Paradox - Parkinson's Law says that work expands to fill the time available for its completion. **Work longer, get less done.** When you establish fixed hours to your work, you find unproductive ways to fill it. Modern work culture is a remnant of the Industrial Age. It encourages long periods of steady, monotonous work unsuited for the Information Age. To do truly great, creative work, you have to be a lion. Sprint when inspired. Rest. Repeat. 要做真正伟大的、有创意的工作,你必须是一头狮子。受到启发时冲刺。休息。重复。 - The Money Paradox - **You have to lose money in order to make money.** Every successful investor & builder has stories of the invaluable lessons learned from a terrible loss in their career. Sometimes you have to pay to learn. Put skin in the game. Scared money don't make money! - The Growth Paradox - Growth takes a much longer time coming than you think, and then it happens much faster than you ever would have thought. **Growth happens gradually, then suddenly.** When you realize this, you start to do things differently—apply effort appropriately, stay the course, and let compounding work its magic. - The Failure Paradox - **You have to fail more to succeed more.** Our greatest moments of growth often stem directly from our greatest failures. Don’t fear failure, just learn to fail smart and fast. After all, getting punched in the face—a few times, but not too many—builds a strong jaw. - The Say No Paradox - **Take on less, accomplish more.** Success doesn’t come from taking on everything that comes your way. It comes from focus—deep focus on the tasks that really matter. Say yes to what matters, say no to what doesn’t. Protect your time as a gift to be cherished. - The Speed Paradox - **You have to slow down to speed up.** Slowing down gives you the time to be deliberate with your actions. You can focus, gather energy, and deploy your resources more efficiently. It allows you to focus on leverage and ROI, not effort. Move slow to move fast. - The Death Paradox - You must know your death in order to truly live your life. [Memento Mori](https://twitter.com/SahilBloom/status/1366072879213813762?s=20) is a Stoic reminder of the certainty and inescapability of death. It is not intended to be morbid; rather, to clarify, illuminate, and inspire. Death is inevitable. Live while you're alive. - The Fear Paradox - **The thing we fear the most is often the thing we need the most.** Fears—when avoided—become limiters on our growth and life. Make a habit of getting closer to your fears. Then take the leap (metaphorically!)—you may just find growth on the other side. - The News Paradox - **The more news you consume, the less well-informed you are.** Taleb calls it the noise bottleneck: As you consume more data, the noise to signal ratio increases, so you end up knowing less about what is actually going on. Want to know more about the world? Turn off the news. - The Icarus Paradox - It is a classic tale of Greek mythology. Icarus crafted wings out of feathers and beeswax to escape an island. He began to fly—the wings working wonders. But he quickly became blinded by his own engineering prowess and flew too close to the sun, which caused the beeswax to melt and sent him plummeting to his death. **What makes you successful can lead to your downfall.** An incumbent achieves success with one thing, but overconfidence blinds them to coming disruption. Beware! - The Shrinking Paradox - **In order to grow, sometimes you need to shrink.** Growth is never linear. Shedding deadweight may feel like a step back, but it is a necessity for long-term growth. 增长从来不是线性的。摆脱无谓的负担可能感觉像是后退了一步,但这是长期增长的必要条件。 One step back, two steps forward is a recipe for consistent, long-term success. - The Looking Paradox - You may have to stop looking in order to find what you are looking for. Have you noticed that when you are looking for something, you rarely find it? Stop looking—what you’re looking for may just find you. Applies to love, business, investing, or life... - The Hamlet Paradox - "I must be cruel only to be kind." — Hamlet In Hamlet, the protagonist is forced to take a seemingly cruel action in order to prevent a much larger harm. Life is so complex. The long-term righteous course may be the one that appears short-term anything but. - The Tony Robbins Paradox - **In investing, the willingness to admit you have no competitive advantage can be the ultimate competitive advantage.** Strong self-awareness breeds high-quality decision-making. Foolish self-confidence breeds nothing of use. Be self-aware—act accordingly. - The Constant Change Paradox - “When you are finished changing, you are finished.” — Benjamin Franklin **The only constant in life is change.** Entropy is reality. It’s the one thing you can always count on—the only constant. Embrace it—be dynamic, be adaptable. - The Control Paradox - More controlling, less control. We have all seen or experienced this as children, partners, or parents. The most controlling often end up with the least control. **Humans are wired for independence**—any attempts to counter this will be met with resistance. ### Daily Coding Problem: Problem #266 [Easy] This problem was asked by Pivotal. A step word is formed by taking a given word, adding a letter, and anagramming the result. For example, starting with the word "APPLE", you can add an "A" and anagram to get "APPEAL". Given a dictionary of words and an input word, create a function that returns all valid step words. ### [4x Smaller, 50x Faster](https://blog.asciinema.org/post/smaller-faster/) > MEMO > ClojureScript/React → Rust/SolidJS Long story short: asciinema-player has been reimplemented from scratch in **JavaScript** and **Rust**, resulting in 50x faster virtual terminal interpreter, while at the same time, reducing the size of the JS bundle 4x. You may wonder what prompted the move from the previous **ClojureScript** implementation. As much as I love Clojure/ClojureScript there were several major and minor problems I couldn’t solve, mostly around these 3 areas: - **speed** - I wanted the player to be ultra-smooth, even for the most heavy animated recordings. Due to ClojureScript’s immutable data structures, there’s a lot of objects created and garbage collected all the time, and for the high frame-rate, heavy animations this puts a lot of pressure on CPU and memory. The new implementation of the virtual terminal interpreter in Rust (compiled to WASM) does it 50x faster. Additional speed improvement comes from porting the views from **React.js to [SolidJS](https://www.solidjs.com/)**, one of the fastest UI libraries out there. - **size** - the output bundle from ClojureScript compiler is rather big. It’s fine when you build your own app in ClojureScript, however when you provide a library to use by other people on their websites, it’s quite bad. 2.6 is 570kb (minified) - that’s over half a megabyte. That bundle contains whole ClojureScript standard library, several popular and useful libraries like reagent, core.async, and finally React.js (via reagent). The new 3.0 is **pure JS** with pretty much **just SolidJS** as the **only dependency** (which is tiny itself). This makes the new player much smaller, ~140kb (minified), even though it includes embeded WASM bytecode (which makes the bulk of the bundle size). - integration with JS ecosystem - ClojureScript is not that easy to integrate with the JS ecosystem. I know, there’s been a lot of improvements done in this space over the years, and I’m sure someone will immediately point me to relevant docs, but it’s still the extra mile you need to go when compared to regular JS codebase, and some things didn’t have any support last time I checked (like embedding WASM in the bundle). Things might have changed here, but first two arguments above still hold, so it was worth it. And as a result, you can now use the player in your own app by importing the ES module provided by [asciinema-player npm package](https://www.npmjs.com/package/asciinema-player/v/3.0.0-beta.4). Now, on top of all the above, I had fun building [terminal control sequence interpreter in Rust](https://github.com/asciinema/vt-rs), using excellent resource for that - [Paul Williams' parser for ANSI-compatible video terminals](https://www.vt100.net/emu/dec_ansi_parser). Special shout out to Paul Williams! But back to speed. It used to be good enough, which is no longer good enough for me. The old player used to be sufficiently fast for probably 90% of the recordings people host on [asciinema.org](https://asciinema.org/explore). It exercised many types of optimizations, like memoization (trading memory for CPU time) and [run-ahead](http://ku1ik.com/2017/04/21/lazy-seq-and-request-idle-callback.html) (which used a lot of memory by precomputing terminal contents for each future frame). The numbers show how many megabytes of text the terminal emulator can process in each player version (tested on Chrome 88): | recording | v2.6 (MB/s) | v3.0 (MB/s) | ratio | | ------------------------------ | ----------- | ----------- | ----- | | https://asciinema.org/a/20055 | 0.61 | 35.41 | 58x | | https://asciinema.org/a/153907 | 0.33 | 24.27 | 73x | | https://asciinema.org/a/44648 | 0.51 | 26.81 | 52x | | https://asciinema.org/a/117813 | 0.82 | 37.73 | 46x | | https://asciinema.org/a/325730 | 0.58 | 26.13 | 45x | 50 times faster on average! Note that the above benchmark represents the speed of text stream parsing (including control sequences), as well as updating emulator’s internal, *virtual* screen buffer. This has been the bottleneck in the previous implementation of the player. The benchmark doesn’t measure rendering of the buffer to the actual screen (DOM), therefore the rendering speed improvements coming from React.js->SolidJS transition are not included here. However, SolidJS has been benchmarked against React.js and other libs many times already, so I didn’t bother proving it’s faster. ### Misc - The ever-growing global suicide rate has become one of the deadliest enemies of mankind. According to the World Health Organisation (WHO), close to 800,000 people die due to suicide every year, which is one person **every 40 seconds**. | [link](https://indianexpress.com/article/lifestyle/health/suicide-kills-more-people-than-war-every-year-survey-5384508/)