HNHacker News
TopNewBestAskShowJobs

dklsf

694 karma · joined July 12, 2011

submissionscomments
dklsf··on Compiling Match Statements to Bytecode
Probably Compiling Pattern Matching to Good Decision Trees (by Luc Maranget) is the scheme used by OCaml (http://moscova.inria.fr/%7Emaranget/papers/ml05e-maranget.pd...).

It explains how to minimize the decisions trees you obtain from a match statement, so you gain a ton of efficiency over a naive implementation, especially for large, multi-column matches.

dklsf··on Asus Announces October Availability of ProArt Display 8K PA32KCX
Here's some specs: https://www.asus.com/displays-desktops/monitors/proart/proar...

8K, 32inch, 275ppi, 60Hz 2 Thunderbolt 4, 1 DisplayPort 2.1

dklsf··on 0+: A double digit Sharpe HFT strategy
Not really sure how this is supposed to be low risk -- I think they're omitting the actual interesting parts of the strategy (that are essential to actually making money).

If you want to be the first or close to the first in the queue on a price level, you're there before it becomes big. So then your "risk-free" closing strategy doesn't work, because if you get traded against, you will have to close out your trade at a loss, since the price level is gone (because it wasn't big yet).

But if you wait until the level becomes big, you will no longer be at the front of the queue, so the strategy doesn't work.

dklsf··on Evidence that Adani Group has engaged in stock manipulation and accounting fraud
It depends what you mean by "untradeable". If the market or regulator decides that the stock cannot be traded at all, you might end up paying a lot of money in fees for years even if you were right.

https://www.reuters.com/article/muddy-waters-asia-short-sell...

dklsf··on Evidence that Adani Group has engaged in stock manipulation and accounting fraud
In some markets, such as Hong Kong, instead of being delisted, suspected frauds are often halted (the stock cannot be traded). So you might end up paying the borrow fee for years, even though you were right about the company being a fraud.

See https://www.reuters.com/article/muddy-waters-asia-short-sell...

dklsf··on Kagi/Orion status update: First three months
I'm really surprised how much a single search query is costing them in terms of compute/infrastructure (1.25 US cents). That buys you more than a minute of compute time on the top vps on hetzner. What's happening behind the scenes during a query?

Getting the compute costs down will probably be a major obstacle to growth, since they'll have to keep prices high (19 USD/month) to pay for their infrastructure.

dklsf··on FDA asks federal judge to wait until 2076 to fully release Covid vaccine data
The issue is that the requester is asking for 329000 pages, and courts apparently previously ruled that a rate of 500 pages/month is reasonable for freedom of information requests.

And looks like more narrow requests for documents would be completed faster: "If Plaintiff decides to request fewer records, then FDA will be able to complete its processing at an earlier date."

dklsf··on Air cargo is suddenly affordable relative to ocean shipping
You stop to refuel in the middle of the trip, rather than making it nonstop.
dklsf··on OCaml for the Skeptical: OCaml in a Nutshell (2006)
What will you use multicore support for?
dklsf··on The Dangers of Super Smart Compilers
It's not really surprising that invalid code doesn't go along with compiler optimizations.

The correct way to deal with this here is probably either _NOT_ using nullptr, and instead using a special null object (similar to the end iterator); or using pointers instead of references (because you really want pointer behaviour).

Their fix is insane, and not something I'd want in production code. Unless you carefully vet your code and compiler version, you should never rely on undefined behaviour.

(There are some cases in the c standard that technically undefined but all compiler vendors have essentially agreed to handle in the same way; so those are fine. IIRC unions are a common example.)

dklsf··on Goldman’s Blankfein on Skipping School Work, Wishing to Be Chinese
I'm not sure where you got your numbers for China's debt from. The IMF says that china's debt has decreased (from 26% to 19%), while the US's has stayed the same (~100%):

  General government gross debt [Percent of GDP]
  Country        Year  2012 2013 2014 2015
  China                  26   23   20   19
  United States         102  104  106  107
http://www.imf.org/external/pubs/ft/weo/2014/01/weodata/weor...
dklsf··on Get rid of boolean function parameters
Ocaml can do this

  let do_something (thing : Thing.t) (logging : [`With_logging | `No_logging])  =
  ...
Even better, it can even infer the type based on you using it (for example matching on it):

  let do_something thing logging =
    let logging_as_bool = 
      match logging with
      | `With_logging -> true
      | `No_logging -> false
    in
    ....
dklsf··on Passport Index – How much power does your passport have?
Doesn't look like the information on that site is correct. Or at least, it disagrees with https://www.henleyglobal.com/international-visa-restrictions... The differences are quite striking, the US isn't even in the top 10.
dklsf··on Why Are Carrots Orange? It Is Political (2009)
How can "some scholars doubt if orange carrots even existed prior to the 16th century", if there are drawings of orange carrots from the year 512?

http://de.wikipedia.org/wiki/Karotte#/media/File:Gemeine_M%C...

http://en.wikipedia.org/wiki/Vienna_Dioscurides

dklsf··on The world's biggest ship – for 53 days
It's a bit slow and inefficient, and also dangerous to do it at sea. So this is done only if space in the port is at premium.

Which means only Hong Kong still does this: http://en.wikipedia.org/wiki/Mid-stream_operation

dklsf··on OpenBazaar is a decentralized Dark Net market that's 'untouchable' by police
The motivation for development was actually producing fertilizer, as it says in the article you linked.