HNHacker News
TopNewBestAskShowJobs

NohatCoder

1,247 karma · joined September 24, 2017

submissionscomments
NohatCoder··on In Serving Big Company Interests, Copyright Is in Crisis
Allowing one megacorp after another buying out their competitors is certainly a failure by lawmakers. Such behavior used to be plainly illegal.

The DMCA is certainly also law.

NohatCoder··on The Car Bundle
There is a pretty big logical fallacy in this article. Bundling intellectual property goods makes sense because the marginal cost is virtually zero. Automobiles cost real money to build.

The notion that an SUV is the whole package seems weird, as the base idea of those models is off-road ability, which virtually nobody needs.

The idea that driving is free once you own the car doesn't make a lot of sense either. Wear and tear is expensive.

NohatCoder··on The Hunt for the Fastest Zero
There is no canonical answer to that question. Compilers wary wildly in implementation details.
NohatCoder··on On Preventing Programming Languages from Interfering with Programming (1975) [pdf]
First we assume that our program needs to solve a well defined mathematical problem. Then we realise that that has nothing to do with any relevant programming problem.
NohatCoder··on Ask HN: What has your work taught you that other people don't realize?
Whatever job we think require the very best in the field are often not performed by the very best. You'd think a book on topic X is written by an expert in X, but the truth is that it only takes enough skill to fool the average reader to sell books.

TV chefs? Mainly have to be good at talking.

People who write libraries, compilers, OS kernels and so forth? All sorts.

So never ever assume that someone is an expert just because they do something "expertly".

NohatCoder··on The BLAKE3 cryptographic hash function
I don't actually have proof that it isn't crypto strength. But comparing it to other algorithms that have been broken, it seems unlikely that it would hold given the rather modest amount of computation done.

I do believe that it meets the requirements for being a MAC function, and I'm completely certain that it is a great non-cryptographic hash function.

NohatCoder··on Boeing docs show staffers discussing ways to manipulate regulators on 737 Max
The important barrier to such thinking is company culture, as long as only a few people think this way others will correct their mistakes.
NohatCoder··on The BLAKE3 cryptographic hash function
I helped design Meow Hash using AES-NI. It is not general purpose crypto strength, but ridiculously fast, targeting a theoretical performance of 16 bytes per cycle on some processors, too fast for memory to keep up. https://github.com/cmuratori/meow_hash
NohatCoder··on Snowpack: Build a web application without a bundler
Browser incompatibilities are mostly gone, where they still exist frameworks tend to do nothing to solve them. I write web stuff and I used to do the dance of testing with a bunch of browsers and fixing stuff. Since IE 11 there have been basically nothing to fix, the browsers really do behave the same.
NohatCoder··on Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript
I guess I am better at writing libraries than marketing. So that is definitely on the todo list now.
NohatCoder··on Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript
Time to shill my own alternative.

https://github.com/NoHatCoder/DOM_Maker

No parser, just a bunch of JavaScript functions that nest nicely, to create dense and readable DOM generation code.

Might be time for putting a 1.0 sticker on it.

As for Bepis, the mechanism by which elements nest seem complicated, as far as I understand it is controlled by sprinkling , and . throughout the string, I don't get why this would be necessary.

NohatCoder··on Ask HN: Solo devs, how do you plan your development?
Fancy tools are for teams, because everyone editing todo.txt eventually gets messy. It is not like you can't use the fancy tools, but if you expect them to somehow improve your work flow, prepare to be disappointed.

The thing about working solo is that you can get away with a lot less communication and writing stuff down. Depending on your memory you probably still should put a few core ideas on paper/file. As long as you are prepared to delete as necessary, putting ideas in code right away might work.

NohatCoder··on My Business Card Runs Linux
It is a gimmick, the value is that he designed it himself and no one else does it. If you just buy a computer card and install your own software, it is just a really impractical waste of resources.
NohatCoder··on Gov.uk content should be published in HTML and not PDF (2018)
It is easier to generate a good document with HTML, you just have to leave out the bells and whistles.

But of course with the HTML+CSS+JS stack being more a programming language than a document format, there is no bounds to how awful one can make it either.

NohatCoder··on Gov.uk content should be published in HTML and not PDF (2018)
The thing is, human consumption tend to rely on machine consumption. We want search engines to index our documents, and we want to be able to search within the documents. These features rely on machine parsability.

It is perfectly possible to generate a PDF file with none of the issues mentioned, the problem is that most people don't have the required control of their toolchain, and a lot of tools will create such issues by default.

NohatCoder··on Gov.uk content should be published in HTML and not PDF (2018)
PDF seems to fit a world-view where the highest objective of a document is to be printed on paper.

From a machine-parsing perspective PDF files are a nightmare. Chunks of text may be broken anywhere, mid-sentence, mid-word. These chunks may appear in the document in any order.

Spaces may be encoded as spaces, or they may be created a number of other ways, like by positioning chunks, or setting character spacing per character.

The mapping from code point to glyph does not need to be pure Unicode, a PDF document may contain a custom font with additional glyphs.

This is all stuff I learned by trying to parse a limited set of PDFs found in the wild.

All of these gotchas are by the way completely PDF/A compliant.

NohatCoder··on Cisco devices must regenerate self-signed certificates before 2020
The generated certificate would also expire in 2020, so it would be invalid immediately.
NohatCoder··on Still Why No HTTPS?
Depends on the stack used. If you have persistent connections you'll incur far fewer handshakes than requests. If you use an elliptic curve scheme key exchange costs are negligible. But sure, if you do one 4096 bit RSA exchange for every request it will be costly.
NohatCoder··on We 30x'd our Node parallelism
The real killer feature is async. Since a modern web request typically spend most of the time waiting for database calls, file system requests or similar, a naively coded server in most languages can handle relatively few requests per thread, so you scale up the number of threads to something like 100 per core, and now the overhead of running and switching between these treads is limiting the performance.

Being used to Node, I was flabbergasted when writing C for Linux* . The file system commands just leave my thread hanging while the result is being generated, if I use it on a network drive it might hang for a minute before timing out, so I have to make a tread for each file system command, solely so that it can stall without bringing down the whole application.

* I have no delusions that Windows is any better, Linux is just what I have first hand experience with.

NohatCoder··on How to write better game libraries
It always baffles me when a library comes with its own arcane build code. Instructions like "Requires Python" invariably turn out to actually mean "Requires hours of debugging".
NohatCoder··on Instructions per cycle: AMD Zen 2 versus Intel
In case anyone is not aware: This is a very small sample of microbenchmarks. When benchmarking very simple tasks like these performance tend to vary wildly between architectures.

For instance instructions are assigned to one of a handful of ports when executed, certain instructions may only be assigned to certain ports, what ports an instruction may be assigned to differ between architectures. If an inner loop use only a few different instructions one architecture may be unlucky in that most of the instructions need the same ports, and so it can execute fewer instruction overall.

For real benchmarking use lots of different complicated jobs. It is not perfect, but it is the best way we have of comparing different processors head to head.

NohatCoder··on I spent 22 years in prison for a crime I didn’t commit
The police is supposed to be a neutral party in this system, I believe a lot of these failures stem from the police failing this role.
NohatCoder··on 0.30000000000000004
Yeah, though that notion tends to come with some conceptual shortcomings, like presuming a power of 10 radix. In the above code the radix is implicitly different on leap years, applying such tricks is usually not possible with a fixed point library or language construct.
NohatCoder··on 0.30000000000000004
This only for dealing with actual money, generally our banking systems have rounding rules that prevent the fractions from getting out of hand.

If you are running an economic simulation you generally don't have to worry about rounding, the whole thing is only approximate anyway.

NohatCoder··on 0.30000000000000004
Money are really best dealt with as integers, any time you'd use a non-integer number, use some fixed multiple that makes it an integer, then divide by the excess factor at the end of the calculation. For instance computing 2.15% yearly interest on a bank account might be done as follows:

  DaysInYear = 366
  InterestRate = 215
  DayBalanceSum = 0
  for each Day in Year
    DayBalanceSum += Day.Balance
  InterestRaw = DayBalanceSum * InterestRate
  InterestRaw += DaysInYear * 5000
  
  Interest = InterestRaw / (DaysInYear * 10000)
  Balance += Interest
Balance should always be expressed in the smallest fraction of currency that we conventionally round to, like 1 yen or 1/100 dollar. Adding in half of the divisor before dividing effectively turns floor division into correctly rounded division.
NohatCoder··on The rise of solar is ‘jeopardising the grid’ and it's a lesson for Australia
Wind mills have to be designed to deliver inertia, older mills generally aren't as this wasn't an issue when they were built. If you have a grid that relies primarily on solar, you might want to build dedicated flywheels to keep it stable.
NohatCoder··on Firefox browser will block the IAB's DigiTrust universal ID
Relatively few companies can sign TLS certificates, and you have the security of the domain name as well. In order for an attacker to steal a TLS session they need to compromise both the certificate system and the dns lookup.
NohatCoder··on RISC-V Foundation moving to Switzerland over trade curb fears
Indeed, and relocating away from that regime is a good first step in cutting ties.
NohatCoder··on Oracle built a 1,060 node Raspberry Pi cluster
Now load any piece of Oracle software onto it and get charged for running 1060 CPUs. Whoops.
NohatCoder··on Interpol plans to condemn encryption spread, citing predators
Most so-called democratic governments are running the same game. They support the word democracy, but when it comes to all the parts that actually make democracy work they often take the authoritarian stance.
← PreviousPage 12 of 14Next →