Comment CAPS-LOCK (Score 3, Funny) 698
Obviously caps-lock is the least used key. you press it only once after boot, then no more.
Obviously caps-lock is the least used key. you press it only once after boot, then no more.
The three keys on the top-right
- Print screen/SysRequest: a poor man's screengrabber at best
- Scroll Lock: does something in MS Office, though I know not what.
- Pause/Break: as far as I know, does absolutely nothing in any application.
Just curious, what OS are you using?
On both Windows and Linux, it's a pretty handy key.
I think I'm going to have to disagree with you here.
The ternary operator is just syntactic sugar for an if..else statement, I don't see how this is any different except for prettier (subjective!) syntax. Also ternary is best used with caution. Complex ternary expressions are the embodyment of "Well, that escalated quickly". Also, you seem to be describing MVVM, which still uses all the conditionals, it's just hiding it from you at the expense of flexibility.
I don't like replacing states with arbitrary ranges of a number. In your example you assume some way of knowing in advance the length or duration of something. This is simply not true in many cases and would give a false indication of knowledge. In your example set [not started, arrived] you imply only being able to know the initial and final state, yet the 0.75 seems to indicate a high level of accuracy. These are not comparable situations. If you had only had knowledge of initial and final state, the number would essentially be treated exactly the same, using conditionals. If you had the accurate information to indicate progress, you wouldn't use states in your model anyway because you'd lose information.
All I'm seeing is some rules of thumb and low-level optimalization strategies --examples where a good solution doesn't need to use conditionals-- but no solid argument against the use of conditional expressions in general. I'm not disagreeing with most of the examples you give, but they are very specific and do not seem to support eskewing conditionals in general.
Don't [...] put yourself in a position where others can post embarrassing photos or videos of you online
Seriously... were you ever a kid or a teen yourself, or were you born a boring old grampa?
Doing embarrassing things is what kids do; it's how they learn what not to do.
The problem is hypocritical people who like to pretend they never did anything embarrassing when they were kids.
Are employers looking at Facebook also mostly a social thing?
The problem isn't embarrasment, it's judgmental people with the power to affect your live.
Do you have an example of code without "if" (or similar) statements that is more easily readable than the equivalent with "if" statements would be?
It seems to me the only way would be to either use numerical tricks, which you say you like even less. And to which I would agree (though I've used them on DSP's because true branching would be dramatically slower). Or to abuse loops (which are essentialy "if" statements with "goto"s) or things like the Strategy design pattern.
Despite your coworkers being stupid, ignorant or both stupid and ignorant, you still have to write code those coworkers they are able to maintain.
Your code none of your coworkers understand might be "good" on some subjective level, but it's not good in the real world.
Unless you have a guarentee that nobody will ever see your code, you are writing code for other people to read. Ignoring this simple reality is... well... it's ignorant.
Well, if a facebook page counts as a "website", I can give you a programming language that everybody can write apps with.
These apps will all look exactly the same and can only display fixed content, but you can program a different title and even a different picture!
I have to disagree.
I've seen smart non-programmers build working and useful SQL statements.
I'm guessing the language you propose is able to magically assume what the developer wants without the developer having to put it in unambiguous statements?
Programming languages are "obnoxious" because they require absolute 100% precision, and people generally don't like to be anywhere near that precise.
Saying "I want a program that adds up numbers" can have literally millions of completely different implementations.
You could make one that fits the ambiguous specifications perfectly, yet is the polar opposite of what you intended.
But please give a small example of your preferred language syntax.
If you think other programmers are dumb because they don't understand your code, then you are the one being dumb by writing that code knowing your collegues won't be able to work with it.
I'm sure they understand XOR and the ternary operator just fine.
A bunch of if statements are a lot faster to read, though, and allow for easier debugging and changing.
Remember that most time spent with code is reading it, and mostly by people who did not write the code.
This is one post where we can be certain nobody RTFA.
They delivered the product as promised, they just never gained the market share to go much further.
This is the same risk you take if you buy any new gizmo in a store.
Remember HD-DVD players?
Nobody got screwed here.
I don't see any apparent upside to the public good.
If vulnerabilities would never be publically exposed, it would remove incentive to fix the vulnerabilities.
Companies generally don't like to spend money fixing problems that they could far more cheaply deny.
The public good of "public disclosure" is that it makes companies accountable for their (in)actions.
It's a naive, domestic operating system without any breeding, but I think you'll be amused by its presumption.