Often I use Python for exploratory purposes. Like, I got a bunch of data, and I want to know if a particular algorithm might work or not. I implement the algorithm, but realize the results don’t look good enough. So I tweak the algorithm, maybe even do major refactoring. Or maybe I realize my visualizations or metrics don’t capture what I need to see. Or maybe I must settle for some compromise?
I iterate on this repeatedly until I find something I’m happy about (or until I give up). Sometimes I end up with something completely different from my initial idea.
TDD won’t help me much here because the end result is unknown. For each iteration of this idea process I might even need to rewrite all the tests because none of them are valid anymore.
I would swap Python with C++. Constantly dealing with stupid runtime errors that could’ve been easily captured during compile time.
Did you forget to rename this one use of the variable at the end of the program? Sucks for you, because I won’t tell you about it until after 30 minutes into the execution.
although in the context of version control, the term master simply refers to the gold master, a term borrowed from the recording industry which refers to the final mixed version of a recording, and does not have a corresponding slave.
Either way, I think “main branch” is easier to say, so it’s a win.
Ok, roadside assistance is maybe worth that price, but the rest are just API calls that cost them virtually nothing to operate. There’s no need for them to keep these functionalities hostage behind some roadside service, other than to be anti consumer.
Not to mention that by paying $90 extra you unlock the functionality to remote unlock your car. What’s the justification for this price? There’s no way it costs this much extra.
One benefit of using dropwhile is that (with a bit of practice) it can actually be easier to read than a for loop. All for loops look similar. You need to read the for loop line by line to understand what it really do.
With dropwhile (or map, filter and reduce), it’s immediately obvious it will drop all elements until a certain condition turns false.
You don’t need to know math or physics to build a house. Sure, it can help if you know those things, but it’s not essential.
Same goes with programming. Math and programming are two separate skill sets, but knowing one can probably help with the other.
Also, a question for you. Why do you want to do Common Lisp? If you’re skeptical about your abilities I recommend to start with a more common programming language (like Python, Java, C#). Easier to find good learning resources.
Learning about reflog was a game changer. Now I’m never afraid of breaking my branch. If I mess up, I can always git reset —hard
to a previous state.
Another game changer was learning that a perfectly valid way of doing squash is to do git reset
to an earlier commit and then do git commit -a
. Saves a lot of rebasing headache.
I think comments should be a last resort when all other methods are inadequate. Proper git commit logs have helped me many times to understand why a certain thing is needed.
Git logs don’t need maintenance either. They always tell what was true when the code was written. Comments need maintenance, and are often difficult to keep updated.
You can write a detailed comment about the whys of a particular function, only for it to become outdated in weeks when the functionality has changed.
If the choice was between Mac vs Windows I would probably go with Mac, as it’s Unix based.
In a previous job I had to use Windows. I think it’s tolerable at best. Thankfully WSL along with the new Windows terminal is pretty good these days. I don’t miss the days when MSYS was the only Linux-like option for windows.
Different computers. My work provide me a dedicated work computer. My work doesn’t really care which OS I’m using on their computer. Only that I’m doing the job, and I’m most productive on Linux.
But if I for some reason had only one computer I would probably dual boot to keep my work and personal life separate.
I’m at least happy head hunters stopped spamming my LinkedIn