English joke of the day
English joke of the day Vegetarian eats vegetables. Guess what’s for the humanitarian.
EN / RU
English joke of the day Vegetarian eats vegetables. Guess what’s for the humanitarian.
Cannabis curve There is a [special page](<https://mathworld.wolfram.com/CannabisCurve.html>) on Wolfram MathWorld dedicated to a very specific equation in polar coordinates. ``` r(θ) = a·[1 + 9/10·cos(8θ)]·[1 + 1/10·cos(
[Chat for discussions](<https://t.me/phys_math_dev_chat>) Feel free to discuss things there [invitation link](<https://t.me/+Au96VWrWbB5iYmIy>)
Walrus operator To finalize previous post. ```python n = 0 while (s := input()).lower() != "конец": n += 1 print(n) ``` I think, it's the most elegant approach. But it uses "walrus operator" which appeared only in python
De Morgan's rule One of the subscribers brought me a problem. Roughly, it sounds like this: “Read standard input and count strings. Stop counting when the user enters конец or КОНЕЦ.” The question was how to write the lo
Algorithm Flood In comments you can bring interesting programming tasks and discuss it
Qbasic and polar coordinates I think it's quite a controversial take. Progress gives us far more powerful computers, instruments nobody could imagine 5 years ago. And still qbasic feels like the best way to start writing
Word of the day: spendthrift Spend means “to give away”, thrift — “to keep”. If you know these words, spendthrift may sound like “keep your money while you can”. And that would be totally wrong. Spendthrift means to spen
Sine cosine machine I’m a physicist, and for me sine and cosine are first and foremost laws of motion: the horizontal and vertical shadows of a pin on the edge of a rotating disc, cast on a wall. Some time ago I decided
Sunflowers. MapReduce. P.S. While writing this post, I realized this algorithm can be improved. There’s some unnecessary work: first I build a (x, y) → h dictionary, and then I rebuild it into h → [(xi, yi), …]. We can g
MapReduce in The Farmer Was Replaced Code discussion. Part II. In the [previous post](<https://t.me/phys_math_dev/86>) we discussed [the code](<https://github.com/tarstars/tfwr/blob/main/sunflowers_ach.py>) which uses ma
Competitive programming guides. When somebody asks about best guides for competitive programming, my first reaction is: * [A. Shen: "Programming: theorems and problems"](<https://sch57.ru/files/pub/prog/Programming_theor
Word of the day I’m in ɔ of this world. Three letters → one ɔ.
GBDTE presentation. Unstable class. I’m working now on a presentation for my upcoming public talk. Here’s a picture that illustrates a small but telling idea: an applicant with exactly three unique phone numbers in their
MapReduce in The Farmer Was Replaced Code discussion. Part I. 27 years ago Google was born. One of its key ideas was PageRank – a “credibility” score for a web page. ([the paper](<https://snap.stanford.edu/class/cs224w-r
Sunflower achievement We have already started to discuss multidrone programming. I applied this technique to get the "Sunflower" achievement. I'm not quite happy with the code yet, but here we are: it works. [code](<http
Heteronym of the day SOW 🐷 noun: "female pig", sound: /saʊ/ 🐷 verb: "to plant seeds", sound: /soʊ/