254 karma · joined September 21, 2013
Don't be afraid of double pointers, although they may seem overly clever at first glance, they can be really helpful for situations like this. Linus's code is considerably shorter, and not particularly difficult to debug or to understand, assuming you understand double pointers.
Another case where double pointers can be really useful is in the interface for linked lists. I.e.
remove_list_entry(node** head, node* entry) { [...] }
Defining the interface that way allows properly removing the last entry from the list. Workarounds like making a list struct and passing a pointer to that are just double pointers in disguise. Returning the new head is error prone, since you can easily forget to reassign it.Double pointers for life!
If land tax were, say, 10% of land value, then buying a house would be at least an order of magnitude less capital intensive, and the homeowners capital risk would therefore be much less significant.
It seems like it ought to need to trace the data flows, but there doesn't seem to be the machinery to do so in the code.
Thanks! This is awesome to play with :).
[1] https://en.wikipedia.org/wiki/United_States_federal_budget
It might, however, go away for cottages/cabins, or other rural buildings. Many people I know have generators at their cottages because the power is unreliable enough, and given the unreliability, the grid must be pretty expensive to maintain.
In the case of captioning the videos, the captioning costs several times more than putting up the videos in the first place. Probably on the order of 100x more. A lot of these lecture videos are just someone with a camera recording the lecture live, someone who would be there, watching the lecture, regardless. They do some trivial editing / splicing, and upload to YouTube. This is essentially free, other than having the professor/school sign off on them doing it.
Once the ADA gets involved, you now have to caption the video while watching, or after the fact, something you likely would not have done otherwise. You probably also have to submit it to some authority in the university now (don't want to get sued!), who will have to rewatch the video and verify the captions.
In the old system, it took you less than 5 minutes of inconvenience per lecture to upload them. In the new system, it takes you 2 x len(lecture) => 120 minutes or so, per lecture. This is a huge tax in relative terms.
Your second statement is irrelevant, we are not talking about what the law does, but what the law should do. And I absolutely think that gifts (and good samaritan acts in general) should be held to a much lower standard than commercial enterprises.
This is not at all unprecedented in US law (or in many places in the world), every state has some form of good samaritan law[1], which protects (to some extent) individuals who act in good faith to aid strangers in need of immediate medical assistance. There is also a federal law indemnifying donors of properly labeled foods, except in the case of gross negligence or intentional misconduct.
These laws are important, because donations result in no benefit for the bearer, so making them cost money is a significant deterrence to charity.
[1] https://en.wikipedia.org/wiki/Good_Samaritan_law#United_Stat...
Of course, our market is far from rational, etc, etc.
FWIW, I don't think that software developers are overpaid, at all. It's a difficult career, requiring years of intense study to do well. Sure, maybe not as much as Doctors, at least not formally, but a lot of that has to do with the structure of medical education in the United States (in particular, the requirement to complete an undergrad degree prior to admission to medical school). The job of a surgeon is certainly more difficult than the average software developer, but compared to a SRE at Google, say, who is working with real, "living" distributed systems that interact in complex ways, I would say they are comparable. If anything, I'd expect, in a rational market, for the SRE to be paid more, because their services are providing for millions or billions of customers, while the surgeon is only providing for one at a time (and maybe a few thousand over their carrer).
At least on Wikipedia, I can check the citations easily...
A better comparison would be to have a double-blind study with McDonalds and "Artisan" hamburgers, and ask participants which they prefer.
There is also the advantage that perf is really testing the actual code on the real hardware. This can get important if you are trying to design code that is cache-aware. Although, with cachegrind, you can set what kind of emulated cache parameters you want, I'm not sure how well this emulates the real hardware, especially if you have multiple threads with cache conflicts.
It's remarkable that such systems still exist (and are apparently being updated, without their foundational cracks fixed) still today!
I'm not sure where you get the impression that Hillary Clinton thinks climate change is "not a problem". Her website certainly states otherwise: https://www.hillaryclinton.com/issues/climate/
Consider that the average inflation rate is 3-4%/year[1][2], and houses generally tend to increase in value at roughly the same rate as inflation[3]. Thus, your property taxes are expected to get cheaper in real cost every year, assuming the housing market is relatively stable.
Of course, in SV, the situation is much much worse than this, because housing prices have grown much faster than inflation due to the booming economy.
[1] https://en.wikipedia.org/wiki/Inflation#Measures [2] http://inflationdata.com/Inflation/Inflation_Rate/Long_Term_... [3] http://observationsandnotes.blogspot.ca/2011/07/housing-pric...
Of course, you could argue that smart pointers shouldn't be a thing, but I think most C++ developers would disagree given the significant advantage of essentially automatic ownership management, at least for tree-like structures (cycles are more complicated, as always).
What would you propose as a simpler solution? Many languages have GC, which is arguably the simpler solution you speak of, but would be unacceptable in C++, since the large majority of applications it is used for require predictable low-latency responses. Manually managing pointers is how you do things in C, but has it's own sets of problems, since it can't be checked in any way by the compiler, so things like forgetting to free, double free, use after free, etc, are common, while with smart pointers these errors are impossible.
int *foo;
foo = malloc(sizeof(*foo));
And avoid the brittleness mentioned.But I think the very way we use computers is restricted by what is possible on commodity infrastructure. The fact that 100Mb/s is overkill for many customers is simply because the average speed is much lower, so nobody has bothered to develop applications that make use of that additional bandwidth. If 100Mb/s became something everyone had, I'm sure we would start to see applications that require such speeds to be useable. I don't know what those applications would be, but I'm sure they would come to exist.
A 56k modem is overkill if you're browsing a text-only internet, but it would be pretty hard to use the internet of today with one :).
Another reminder to always test the edge cases (as though we needed another :) ).
The only problem I noticed is that clicking the footnotes does not work, which makes it harder to evaluate the legitimacy of an edit (well, it just means I have to have the current article open as well).
https://docs.google.com/presentation/d/1aigINmRR7fw_ml8rz0rJ...