s28l
Joined 5 years ago
Joined 5 years ago
It may be the case that this is a recent phenomenon (though some other commentators disagree), but without providing detail on what movies the author feels avoid this pattern, they make their argument impossible to refute or engage with. (It also insulates the author’s tastes from criticism, which I suspect is part of the motivation)
If you are making a turn the centrifugal force will push the fluid away from the axis of rotation. There is likely a level sensor only on one side of the tank, so the turn might push the fluid away from the sensor enough to trigger a warning.
The sensor likely has a time component to avoid triggering every time you make a turn, but if this bend is long enough, maybe the fluid is displaced long enough that it overcomes that minimum time.
I'd also be interested in seeing how this performs when the data isn't allocated in one chunk (which seems to be the absolute best case scenario for this trick). Will it end up worse than the "naive" version due to all the branch mispredictions?
I also don't think this is a "smartass" answer:
> This is an irrelevant question unless you're focusing on recent grads with no job history.
That is a straightforward statement of his opinion. He's perfectly within his rights not to answer any question, and explaining why he chooses not to is hardly an unreasonable thing to do.
I think your first point is fair, but I think you're overselling things here. Yyou can only short Bitcoin, not all crypto, but the real issue is that the Bitcoin futures curve is in backwardation, which implies a certain financing cost to go short.
The settlements for the various contracts can be found here[0]. Nearly all of the volume is concentrated in the front month contract (Jan 23 at the moment), so if you want to be able to trade any size at all, you'll have to do so by selling that contract.
However, the issue is that the future price is consistently lower than the spot price. So if you bought a Bitcoin today and then sold a future for the front month (i.e. so you locked in the price you could sell the Bitcoin at in the future), you would be guaranteed to lose money.
And you will effectively have to do exactly that every month: as your short contract approaches expiry, you'll need to roll it over for the next month's contract. As the front month gets closer to expiry, its price will trend to the Bitcoin spot price, meaning you'll have to buy it back at a higher price then you will get when you sell the next month contract.
I don't have access to the historical settlement prices for the CME contracts at the moment, so I can't estimate the exact roll cost you'd pay over the course of a year. If we guess that it's about $100 each roll, then you'd pay $1200 over the course of the year per bitcoin (as well as having to commit 50% of the price of bitcoin in margin).
The OP posted 185 USDC net as collateral and has a short position of 450 USDT, which he's paying about 13% on. In the CME case, the collateral requirements are higher (50% of the notional shorted) but the financing cost is lower (less than 10% of notional shorted).
[0] https://www.cmegroup.com/markets/cryptocurrencies/bitcoin/bi...
However, the bigger issue with that code is that it can easily stop working with a simple refactor. Consider:
void foo(std::unique_ptr<int> ptr) {}
void bar(std::unique_ptr<int>&& ptr) {}
int main()
{
std::unique_ptr<int> p1{new int{1}};
std::unique_ptr<int> p2{new int{2}};
foo(std::move(p1));
assert(p1 == nullptr);
bar(std::move(p2));
assert(p2 != nullptr);
}
Neither of the above asserts will fire, but from the calling site, they look exactly the same. In my opinion, the more explicit option would be to do something like `bar(std::exchange(p2, nullptr))`[0]: overload (5) https://en.cppreference.com/w/cpp/memory/unique_ptr/unique_p...
Just to be clear, this is the archive of a puff piece published on the Sequoia Capital website: they were talking up their book. They took it down when they wrote their investment in FTX down to $0 (from over $200mm). It was neither published recently nor by a MSM outlet.
[0] section III of https://www.sec.gov/investor/pubs/regsho.htm
struct A;
enum B; // as you pointed out, not allowed by the C++ standard
// fine to declare, define, and invoke
void fooA(struct A*);
void fooB(enum B*);
// ok to forward declare, but you can't call them
void barA(struct A);
void barB(enum B); void foo();
#pragma unreachable
class bar
{
#pragma unreachable
};
namespace foobar {
#pragma unreachable
}
But pragmas can generally be used anywhere, barring tokenization issues. The end result is that `pragma unreachable` would likely end up turning into a magic function call inside the compiler, since it really only makes sense in a spot where you can invoke a function.Also, I think you are conflating pragmas with `__attribute__`, which is how you set per function optimization settings. If you do that with pragmas, then it isn't limited to a single function.