The first part resonate a lot with me. I wanted to learn Russian (because why not ?), I intuitively thought the Cyrillic alphabet would be the hardest part of all, like it's another alphabet and you can't read anything right ? Sounds really difficult...
Actually it's the easiest part of the language because it's 99% phonetic with some few exceptions, the whole alphabet is in reality quite small and it was actually easier to learn how to read Russian than reading English. The hard part is actually more the grammar (with those cases) and the vocabulary more than the reading itself. I still have a very basic level but the alphabet part took like only 4 hours maybe to remember them all.
But it's also the same when coding, the hard parts are not always where I expect them to be.
The hard part of optimizing code is to find areas were your code is weak at and taking too long to do something.
In my best practices and I learned this from a video by Grace Hopper, is to use less code to do the same thing. Less code takes up less memory and usually runs faster.
Just writing code and then compiling it without any errors doesn't mean it is done. You still have to optimize it and do security checks as well as quality checks. You still have to check for bugs and side effects. You have to use it and think like a user would to see how the user would see it.
Less code is not really that important anymore (within sensible bounds) Clarity to whatever poor shmo has to maintain it is often much more important than saving 5 lines with some clever bit twiddling hack.
Unless of course you are having performance issues and you have identified this code block as the issue.
>> Less code is not really that important anymore (within sensible bounds) Clarity to whatever poor shmo has to maintain it is often much more important than saving 5 lines with some clever bit twiddling hack.
I don't think many people will advocate reducing line count by stuffing the same processing into fewer lines using clever tricks. What should always be considered a good thing though, is cutting down on the line count by changing the algorithm/strategy, using better suited data structures, by trying to 'do less' and get the same result, not trying to support every thinkable corner case you will never run into, by preferring multiple simple implementations of the same thing for different corner cases, over one single complex kitchen-sink solution, by not re-inventing the wheel and using tried & tested libraries/frameworks, etc.
I know it sounds like a terrible cliche, but any line you don't write, is a line that can't contain bugs ;-). Over the years I've learned that almost always, simplicity is preferred over complexity, even if it implies a little bit of duplication, or an implementation that is 'less awesome' because it 'only' does what is needed for the application.
This reminds me of babies. A lot of people assume that changing diapers or sleep deprivation is the hard part of having a baby. For me, though, the hard part is actually just that babies are kind of boring, and the boringness of having to watch them constantly grinds you down.
That definitely wasn't what I was expecting to be hard when considering whether to have a baby.
(Fortunately they get more interesting over time.)
The trick I think is to remember that while they don't say or do much, they're listening. So you can talk to them a lot. Tell them you're entire life history. Ask them questions about the meaning of life. Lots of fun to be had, if you're not dying from lack of sleep.
Sleep deprivation was definitely the most common thing mentioned amongst my friends.
A close second though was definitely the boringness of watching them constantly. My best friend said his showers and time on the toilet are 2 - 3x longer as it's his only respite.
My kids aren't that old yet, but "interesting" is a still a good description. The world through the eyes of a 3 year old is pretty comical.
Dinosaurs? the best thing in the world. We don't have enough toys, books, and videos even available to us to satisfy. Toy tools? he's "fixing" everything. Usually with brute force. Toy pliers broke, so toy saw was tried and found to be a far superior tool for everything. It is a better hammer, better wedge, better saw, and better chisel than any other piece of plastic in his arsenal.
Then again, the level of intelligence is hilariously lacking. I mean, he's 3, what do you expect? Either way, you have to choose your activities carefully so that you can watch them without becoming a sleep-deprived under-stimulated zombie.
"boringness of having to watch them constantly". My third child is 2 and he is not boring. He is very creative. I think the problem is "watch them constantly". This is a source of frustration for us as parent (we have so many other things to do) and not good for them (not socializing). I think it is useful to delegate to nursery and to be available to play with our children when they are back home.
Maybe this is "horrible", but can't you just use some kinda leash? Let's say you leash the baby, within your field of view obviously, then you do whatever you feel like.
I feel like this is good advice but presents only one side of the coin. Underestimating how difficult something is, is exactly what leads to ''planning fallacy''. I would rather err on the side of caution and overestimate how difficult something is
The most important time to apply the advice from the article is after you have decided a project is worth your time and before you start planning in earnest.
The examples of difficult subject matter the author gives (particularly math) are so intimidating to some people that they miss out on a lot of great stuff because they conclude "I could never do that".
I don't think the author wants people to make poor time estimates and suffer budget overruns.
To me, the message of the article reads: "If you think something looks worthwhile but difficult, take a stab anyway. Often the hairiest, prickliest parts of the undertaking from an outsider's perspective aren't that tough at all once you're in the thick of it"
I 100% agree with you about how valuable conservatism is when you're planning, but I think the author's encouragement is intended for people who haven't even considered planning yet.
Thanks for stating it more clearly than I did! You've nailed it. It's always bothered me when people dismiss their ability to learn a thing, because they think some part will be difficult. They really have no idea. Yes, the task as a whole will have difficult parts, but we as individual human beings are far more capable than we give ourselves credit for.
My take-away was - never estimate confidently without knowing anything about the task. Because the initial assumptions might be very incorrect. Invest maybe 2-5% of the time to start doing something (ie begin learning Korean to realize that it's a phonetic language, and reading is easy within just 1 day). This will allow you to come up with the right estimate. Thoughts?
I have a framework of thinking about learning new things, which I sometimes call the 10-100-10k approach. I wrote about it year ago[0], and the responses helped me refine it.
I think the investing 10 hours in learning a new thing is more than enough to get the initial estimate you describe. Probably even 5 would be enough. That's 10 pomodoros. It's something I'm willing to consider to throw at totally random things to see if they are actually as hard as I think, and if I actually want to learn them.
Most people don't really spend even 15 minutes, to the clock, on things they think are hard to learn - and so underestimate just how much you can progress with as little as few hours, if you actually sit down and do it.
In my experience it's usually not as tricky as predicted, but requires more boilerplate, cleaning and communication with other people, so it takes more time than predicted.
Personally, when troubleshooting software, I've always found that stating assumptions, testing them both for false and true values, and writing the results down, makes for good (albeit sometimes slow) forward progress.
Of course, you get those bugs that occur with seemingly zero difference in your methods, and that's when you need to start thinking creatively...
This is honestly how I felt about shaving with a straight razor. Everyone I spoke to about it was like "you're crazy! you'll cut yourself. At the very least use a safety razor to warm up to something like that." I had a gift card to Art of Shaving, and bought a shavette.
Two weeks in, I haven't cut myself once, and I shave faster and better than I ever have.
As a safety razor user of about 7 years now, I regret to report that my experience is that eventually something will go wrong and you'll cut yourself in an annoying way. In my case it took 5+ years. Two weeks with a new technique is ludicrously early to come to a conclusion.
you never cut yourself? Parts of my neck were nicked repeatedly in the first month. Most interesting part was that not once did it actually hurt, it was just that sharp.
Still though, the blade price alone makes the effort worth it. Plus I had a few solid months of a feeling of superior manliness, and the glory of using a shaving brush has yet to wear off in the last year and a half. How did I go years without using a shaving brush?
For about the last year that I was in the military, I started using a shaving brush and safety razor. It was the best, though I usually had to shave twice (down then up) to get the closeness required of a military shave. Reading this and thinking back, perhaps I should have tried a straight razor. I never shave anymore so perhaps it could be something new to try.
Actually it's the easiest part of the language because it's 99% phonetic with some few exceptions, the whole alphabet is in reality quite small and it was actually easier to learn how to read Russian than reading English. The hard part is actually more the grammar (with those cases) and the vocabulary more than the reading itself. I still have a very basic level but the alphabet part took like only 4 hours maybe to remember them all.
But it's also the same when coding, the hard parts are not always where I expect them to be.