Comments

BerislavLopac 10d
Time flies like an arrow, fruit flies like bananas.
timr 10d
I have the same problem (i.e. terrible short-term memory, though my long-term memory is fine), and I've picked up a number of compensating behaviors over the years. By far, documentation is my #1 go-to strategy. I document code extensively, even if I'm the only person who is ever going to read it again. People have mocked me for this over the years, but I believe it's a superpower.

Most programmers believe a number of blatant falsehoods about documentation, with the most prevalent being "comments go out of date quickly, so there's no point in investing in them". Maybe I'm just hyper-aware of it because my short-term memory sucks, but code comments have saved me on so many occasions that they're simply not optional.

You can document your code. You can keep it up to date. It isn't that hard. You just don't want to.

jbandela1 10d
> Your mind is for having ideas, not holding them.

I will have to disagree. New ideas are rarely totally new, and often build on old ideas. Keeping old ideas in your brain will help you come up with new ideas.

One of the big advantages of having stuff in memory is that you can do background processing.

I can't tell you the number of problems I have figured out while going for a long walk, or driving in my car, or even sleeping (all of a sudden I wake up with the solution).

xavdid 10d
I've noticed as I've gotten older that I lean more on remembering pointers to information rather than the specific information. I know something exists and can find it quickly, but may not know it off the top of my head.

For example, how to get the length of an iterable in a given language. I may not remember the function name (or if it's a top-level function vs a method) but I know I can search "string length in $LANGUAGE" and find it. This scales better than memorizing every language feature I'll ever use.

---

PS: Dash is a great mac app, highly recommend. Your job will likely cover it if it's something you think you'll use.

orangepurple 10d
Improving your own brain with memories and knowledge is like greatly increasing the size of a CPU L1 cache and the improvement in execution performance is similar
kazinator 10d
> On the other hand, the information for everything that we need to write code today is usually no more than one click away.

Sure! If you just assemble a page with about 500 button or links, and know which one to click on to get the needed information, everything is a click away!

ianbutler 10d
And here are the docset feeds, which link to the actual docsets on Kapeli for Dash.

You of course can't use them without permission, but I've found them interesting before.

https://github.com/Kapeli/feeds

0xbadcafebee 10d
A comparison of documentation generators: (https://en.wikipedia.org/wiki/Comparison_of_documentation_ge...). Sphinx and Doxygen seem to be the ones still maintained with the most features.

Old man mode

Remember back when Linux systems just came with huge packages of documentation? You could do anything offline by reading man pages or looking through /usr/doc/, /usr/share/, etc.

dkjaudyeqooe 10d
I don't try to remember anything and really don't see the point. There's no way you can remember everything you need, so why even try?
ajudson 10d
Memory is important, it doesn't matter how nice your documentation search is http://augmentingcognition.com/ltm.html
f311a 10d
Too bad we don’t have a modern replacement for the man command in terminal that could provide the same features.
impulse7 10d
I made something similar to have a key-shortcut quickly show a 'cheatsheet' for whatever application window that is in focus in i3(window manager). If no cheatsheet exists it opens an empty document so I can fill it in and save it.

https://github.com/tonybjorkman/i3-cheatsheet-hot-key

Someone 10d
Before reading the article, I googled whether ”the memory of a fruit fly” is a compliment. It’s not.

https://kids.frontiersin.org/articles/10.3389/frym.2017.0006...:

“Normally, flies will remember very well and will get an A if they are tested a few minutes after learning. But if there is long time between learning and testing, which for a fruit fly is 1 day, they will forget and get an F”

A fruit fly lives for 40 to 50 days, so 1 day isn’t a long time to remember things for them.

https://phys.org/news/2017-03-fruit-flies-memory.html:

“Flies form a memory of locations they are heading for. This memory is retained for approximately four seconds. This means that if a fly, for instance, deviates from its route for about a second, it can still return to its original direction of travel.”

I couldn’t find how many things they can remember simultaneously.

mgaunard 10d
Using third-party libraries may be more costly than developing your own.

It's much easier to modify and maintain your own software which is purpose-built to your needs than it is to maintain somebody else's code that was built to their needs, and was probably overcomplicated to make it as a generic library.

For a compiled language, you have the extra complexity of integrating its build system into yours.

So I'd say you should still weigh carefully whether you want to pull an extra dependency or not.

pessimizer 10d
Never heard of Zeal before in my life; glad to have read this blog. Also thankful to this guy for making it easier to get docs into Zeal. People are the best.
Melatonic 10d
Simple solution: You need to download more RAM!
cardanome 10d
I am on the opposite end of this. The older I get the more I see the value of rote memorization.

Just taking the time to actually learn what the standard library of the programming language you are using provides can dramatically increase your productivity. The same with important libraries you are using. Yes, it is too much to memorize everything but just knowing what actually is there will help you a lot. You can not search for something you don't know exists.

I also really love working on solo projects because I tend to memorize the general shape of the code I am working on. This makes me so much more productive. I might not remember every single line of code in detail but will have a pretty clear idea of the shape of the program. This means I can plan new features or doing refactors in my head and see if they would work. I don't need to sit in front of the computer. I can do the hard mental work while taking a shower or going for a walk and can type in the code afterwards.

Anyone else work like this?

masukomi 10d
I wrote Private Comments[1] specifically to address this problem in code. My coworkers can maintain context about how a given thing works months after the fact. I can't. So, I leave private comments throughout the code. Things they'd never want committed, but save me hours of re-leaning when next i encounter a given piece of code.

Currently has plugins for Vim (proof of concept) and Emacs (actually good). It'd be lovely if one of you folks would make a VSCode plugin for it. I've thoroughly documented the API and diagrammed the code flow you'd need[2], so that this would be as easy as possible to add to your favorite editor.

[1]: https://github.com/masukomi/private_comments

[2]: https://masukomi.github.io/private_comments/

karmakaze 10d
> Having all API docs one key press away is profoundly empowering.

> While Dash is a $30 Mac app, there’s the free Windows and Linux version called Zeal[1], and a $20 Windows app called Velocity[2]. Of course there’s also at least one Emacs package doing the same thing: helm-dash[3].

[0] https://kapeli.com/dash

[1] https://zealdocs.org/ [2] https://velocity.silverlakesoftware.com/ [3] https://github.com/dash-docs-el/helm-dash

01100011 10d
I started having this problem around 40. A lot of it came from a heavy marijuana habit that seemed to reduce my working memory with the tradeoff that I became more clever at small-scale problems(I call it a tactical vs strategic tradeoff).

Quit smoking pot and things got a lot better for a while, but then things seemed to resume their downward slide. Sleep apnea didn't help, and treating it made things better for a while, but that slide continued.

Now I just try to manage it with lots of notes, scripting everything I can, and trying to simplify my workflow wherever possible. Hopefully things stabilize in my 50s or I don't think I'll be good for much engineering work beyond that. I have a number of dopamine-related movement disorders though so there may be some special issues in my case.

i_am_toaster 10d
I was really excited because I have the memory of a goldfish but am the most hyper-productive person I know. I was curious about the techniques and a write up on various techniques that this person uses to compare them with my own.

Then 2 paragraphs in I run face first into a 5 meter high stainless steel marketing pitch. Wtf.

betwixthewires 10d
Zeal looks cool, I'm going to use it, but it has a lot of problems.

- the last release was October 2018. The repo shows activity up to 2 months ago, and I'm sure the last release works fine, but it doesn't seem very active.

- the installation documentation is very much lacking. The "make -B build" on the README doesn't work, the build instructions on the wiki is empty except for per distro instructions, the package release for Debian doesn't exist, and the ppa points to an old IP.

That said, I got it working. It seems pretty cool, haven't used it yet, but from what I can see, it is very mouse centric and no keyboard controls, has popup windows and a system tray icon (I loathe them), so for a tiling wm not quite the best. But it does what I need it to do: download docsets, keep them up to date via the RSS feeds for Dash, search them.

I'd love a tool like this but more keyboard oriented, specifically vim like keybinds but any keybind system would work. I know there's an emacs package "helm-dash" but I don't use emacs. I might try it just for this tool.

All in all I think this is going to make my life a lot better. I like to disconnect from the world, but I want to be able to code while disconnected and zeal could enable me to do that.

unity1001 10d
Even if someone can remember every second in any given day with picture-perfect detail, taking notes, documenting stuff will allow him to do MUCH more than he normally could.
chazeon 10d
I'm a computational physics student; my work involves using multiple software with varied options. Frequently, I need to check to make sure all my parameters are correct, and having these docs at hand is important for me. Using offline documentation is always faster than Google. Since the docsets for these special pieces of software for computational physics or quantum chemistry is lacking, I build these docsets myself. Up till now, I have written code (and sometimes scrape web pages) to build these docsets myself:

1. LAMMPS: https://github.com/chazeon/lammps-docset 2. ASE: https://github.com/chazeon/ase-docset 3. VASP: https://github.com/chazeon/vasp-docset 4. QE: https://github.com/chazeon/qe-docset

darkteflon 10d
Dash looks excellent. Insta-buy for me. I only wish it officially supported Unreal Engine (cf, Unity is supported). Epic doesn’t make offline docs available and the existing community projects tend to be out of date.
twodave 10d
I can still remember a lot of my early code (and much of it is still running in some form 15 years later). As I’ve grown and gained more responsibility I spend a lot more time on concepts and design than on particulars, and I think that actually makes the particulars harder to remember. This is doubly true because I also spend less overall time building/iterating on those specific pieces. That plus the sheer number of things I work on in a given day, at this point I can forget code I wrote last week… but it doesn’t really matter because I know how to read it later if I want, and I can always build it again anyway.
abhgh 10d
I tend to work on a lot of ML projects in my personal time, even if that means I am simply benchmarking something. Which means I generate a lot of data (in form of results) and conclusions based on them. Documentation, lavish commenting, proper file organization (also documented), READMEs at different levels are necessary for me to manage such breadth and scope. My memory is fine (unless I don't know what I'm forgetting ;-)), but there's only so much I can pack in for the amount of things I want to do.
scoutt 9d
My memory problem is not with documentation. Usually my IDE takes care of it.

As soon as I hit 40, I can't remeber what I did last week or before that. Did I solve that problem? Which customer complained about it? Where did I put that PDF?

Fortunately I am very organized, and I leave clues for myself all over the place. Readme files in named folders, details in commits, email myself with some information.

But more than often I am asked "was X display compatible with XYZ board?" and I can't give a direct answer anymore.

continuational 9d
Documentation is available at a keypress in an IDE such as IntelliJ IDEA, in languages that support developer productivity.
cvccvroomvroom 9d
Haha. Same. I would fail a trivial pursuit-style magical but useless details interview or an A+ certification exam. I've been using Dash for about 10 years. Sadly, it lacks Rust crates support and really hasn't moved anywhere in 4 years.
relex 9d
Thanks, I just ordered a Dash license, seems like an incredibly useful tool to me, good software should be supported!
anktor 9d
This article is great for me since I discovered zeal which is something I knew I need it but did not have a name for it.

Now I want to be honest, I have been trying for a bit over an hour to add ANY documentation that is not included by default. It's way too complicated. Has anyone found any success?

Docs from pyspark, azure data factory, databricks, anything big data related would be a gift for me. But the steps are overtly complicated.

Specifically, in the "Building documentation" part of the article, it's where you are supposed to use doc2dash and use to add new info. If someone or even the author has managed to add any not supported doc, and wants to share, it'd be much appreciated.

Otherwise I am left with the question, how many hours are you supposed to spend in order to save time with each search? Because this programs seem unbalanced for people without the know-how to even start.