I don’t understand how Cyberpunk and No Man’s Sky were the ones that “burned” you, they’re both great games? GOTY material even?
I don’t understand how Cyberpunk and No Man’s Sky were the ones that “burned” you, they’re both great games? GOTY material even?
Good luck
What would be an example where you need different logic based on a number’s parity? Why wouldn’t you write logic that ignores the number’s parity?
Part of getting better as a programmer is realizing which stuff doesn’t matter, and writing less code, as a result.
(however, I don’t get why more loops and ifs makes a function harder to test, I’m just going to trust you and that I’ll find out later.
Well, it’s fairly easy to explain - each branching statement in your function doubles the number of discrete paths through the code. If there’s one if
statement, there’s two paths through the code. (The one where the if
predicate is True, and the one where it isn’t.) If there’s two if
statements, there’s four paths through the code. If there’s three if
statements, there’s eight paths through the code.
In order to test a function completely, you have to test every possible path through the code. If you used three if
statements, that means you have to devise and write eight tests just for the different code paths, plus testing various exceptional cases of the function’s input (“what if all inputs are 0”, “what if all inputs are null”, “what if the integer is a string”, etc.) That’s a lot of tests! You might even have to write tests for exceptional cases combined with different code paths, so now you’re writing eight times the number of tests you otherwise would have had to.
Whereas if your function doesn’t branch at all, there’s only one path through the code to have to test. That’s a lot fewer tests which means you’ll probably actually write them instead of saying “well, it looks like it works, I won’t spend the time on tests right now.” Which is how bugs make it all the way through to the end of the project.
I suspect “you’ll fail the test if you use break
” is more of a joke by your teacher than an actual grading rubric, although if you used it more than twice in the same test I wouldn’t award you better than a B.
Is there a benefit to not using breaks or continues?
The benefit is that you learn to write non-branching code. That’s important for beginners, who tend to write very complicated and complex code with lots of branching, which they then discover they’re not able to test and debug. Barring you from using break
and continue
forces you to write more abstract code to achieve the same level of function with less complexity, and that’s how programmers advance in skill - simpler, more abstract code.
Ultimately it’s an effort to kick a crutch out from under you. Whether you think that’s appropriate for a teacher is up to you, I guess - I’m inclined to think it is, but many students don’t respond well to being challenged.
Now all of that value truly is gone. Sucks to be my kids I guess.
Why do you think it sucks to be your kids? They inherit a free fancy house and any of your securities that weren’t sold to pay the note.
I mean, it sucks for them that their cool dad is dead, but maybe they take comfort in the fact that you went out doing what you loved (raw dog nutting into bitches.)
But it only moves the problem.
Yes, it moves the problem until after you’re dead, and it moves the problem into the future when the value of your securities will have substantially grown, thereby reducing the real cost of your house. Both of those things are good!
If I borrow against the securities, I get cash. I use that cash. I now have zero cash (again).
You have zero cash plus a property asset. The value of that asset will grow as well. Both the asset and your securities are, in fact, growing in value at an interest rate that’s greater than the interest you’re paying on the loan.
So you’re getting free money. It doesn’t come from nowhere, of course; it comes from the future people who buy your securities. They essentially paid you in the past to buy a house, and they’ll be paid to have done so by people who need to enter the securities market later on (by buying securities.)
Who will pay the debt when I die?
Your estate, via the value of the securities at sale, whose value will have increased in the intervening time. What do you think is the downside, here?
If you’re only going to live another 10 or 20 years but you have $1M stashed… do you take the $1M now and buy a fancy house? Or do you keep that $1M going for the… checks math … few tens of thousands of dollars it’ll earn in yearly dividends?
Borrow against the value of the securities, obviously, like people with actual money do.
Sometimes it’s so obvious that only poors use the internet.
The American consumer is the worst-behaved, most deranged, most thievery-prone they’ve ever been in history. “The customer is always right” thinking is endemic. Roving bands of Karens are straight-up assaulting workers. People want everything for free and figure “gratis” means “loot an entire two-armed carry.” Not to even get started on the fucking shoplifting!
When people abuse a privilege, you take the privilege away, from everyone. It’s pretty simple. If you want a retail experience where you feel privileged and taken care of then you need to be going to places that have some kind of mechanism to keep the hoi polloi away. A membership fee, an unusual location, some kind of barrier to entry.
I think if you want to understand racism, you can’t understand it as the failure to have certain pieces of knowledge. Racists generally aren’t unaware that people experience suffering when they’re held down or held back from their appropriate station in life.
What racists generally believe, if you’re trying to be maximally charitable to the views of racists (ugh), is that human suffering also comes from pushing people into societal roles that are above their station. The individual so pushed suffers, and society suffers for having “the wrong people” in important roles. For instance, that’s the view that held that slavery for Black Americans was good for them.
I think a racist in that strain would play the Detroit game and not be convinced, since the game likely doesn’t address that position at all.
Every game has issues at launch, that’s why they launch them