that’s one way to swing the pendulum all the way back to the 1970s
that’s one way to swing the pendulum all the way back to the 1970s
You probably don’t have to write to specific broswers. Just stick to the baseline and you’re golden. Optionally use a headless chrome for e2e testing to be sure.
I’ll admit that in 10 years using git, I don’t think I’ve ever used reflog once.
don’t forget to activate your linux distro
it does work though, on windows i can see ads and intrusive crap all the time. Linux distros don’t bother you at all, it’s like linux is not even trying at this point.
tldr
Scientists using macs connecting to servers and other machines running Linux.
Unknown share is high too; Linux usage on desktop in Antarctica could be as high as 15%.
Because you’re assuming foo
won’t be renamed when it becomes a function. A function should start with a verb, say get_foo()
, because just foo()
tells me nothing about what the function does (or what to expect as output). If you make it a property, get_
is implicit.
So if the age is computed from the year of birth for example, it’s really e.g. thing.age
or thing.get_age()
- both of which are fine, but I’d pick the property version.
that we agree on: properties should be cheap to compute.
Making a simple ternary condition as a function instead of property is a wasted opportunity to make its usage cleaner.
Properties make semantic sense. Functions do something, while properties are something. IMO if you want to name something lazily evaluated using a noun, it should be a property.
The misleading behavior is about what you expect to execute in the source code you’re looking at vs what’s actually executed.
What you describe is a logic ambiguity that can happen in any program / language.
Totally agree. The hardcoded isAdult: true
repeated in all #2 examples seems like a bug waiting to happen; that should be a property dynamically computed from the age during access time, not a static thing.
deleted by creator
That’s part of the problem. Different number of whitespaces indicate different nesting levels and the YAML spec does not enforce them. These two horrible YAMLs are valid and are not equivalent:
a:
b:
- c
- d
- e
f:
"ghi"
a:
b:
- c
- d
- e
f:
"ghi"
You can’t say python’s whitespace usage is as bad as yaml’s. YAML mixes 2 and 4 spaces all the time. Python scripts don’t run if you write this kind of crap.
And whitespaces is really just the tip of the iceberg of YAML problems…
yes, from my other comment
the only mistake of Python when it comes to whitespaces was allowing hard tabs
but that’s easily fixed with an editor setting - on the other hand, unbalancing braces (and not realizing it) is too easy all the time.
YAML sucks because, among other things, indenting it is not obvious.
In contrast, the only mistake of Python when it comes to whitespaces was allowing hard tabs, which makes it too easy to mix them if your editor is not configured.
Improper indentation stands out more than missing or unbalanced braces and it’s really not an issue to delimit code blocks.
False dichotomy. Optional braces are bad practice because they mislead the programmer that is adding an additional clause to the block.
This misleading behavior wouldn’t happen in Python, as it would either be invalid syntax, or it would be part of the block.
Indentation problems are pretty obvious to the reader. Even more than missing or unbalanced braces.
I’m a native pt speaker and I had never thought of the word as slur. I remember it being commonly said on TV, music, and written on newspapers without this connotation. It was certainly more common than the preferred alternative “mestiço”.
C was my first language some 18y ago, and I wouldn’t recommend it to anyone starting today. If anything, learning C is a great way to teach why, maybe, we shouldn’t be using it to build customer applications, web servers, and whatnot.
Keep your gold, I’ll stick to sane error messages, memory management, a packaging system, and a dozen other things that actually make working on multiple projects somewhat doable and not a constant fight against seg faults.