omegaham

Joined 13 years ago

Karma
2,161
Submissions
585
Member since
Apr 7
Oregon software engineer. USMC 2009-2014.
View on Hacker News

Recent submissions

Comment · 8 months ago
nethack.alt.org still maintains a telnet server!
Comment · 11 months ago
See also Uiua, a newcomer to the "extremely cool but completely incomprehensible language" family!
Comment · 1 year ago
A more obvious setup to the joke is

"Is there a doctor on this plane???"

"Well yes, but I defended my thesis in comparative literature..."

Comment · 1 year ago
Since even a phone has enough processing power to make Stockfish play better than a super-GM, the Faraday cage isn't enough to prevent, say, someone tapping the position into a computer on their person and feeling for some sort of vibration[1] in response. It takes very little information to represent a position, and commentators have pointed out that the minimum amount of information required to produce a decisive advantage is 1 bit ("A winning move exists").

[1] Yes, the ribald jokes have already been made

Comment · 1 year ago
The adjournments in The Queen's Gambit were rendered obsolete after chess engines became strong enough to be useful in analysis. The last year that they were permitted was 1996.

Match play at the World Championship (where the two players play each other repeatedly for many games) involves a ton of inter-game coaching and work as each player's team goes over what went well, what went wrong, and how the next game should be approached.

Round robin play in small fields also has a significant amount of preparation because the schedule is known in advance, so players will know whom they have to play the following morning and will prepare accordingly.

I'm not comfortable saying that Hikaru does exactly 0 preparation for 3-minute Chess.com blitz games, but it's probably pretty close to 0.

Comment · 1 year ago
Unopened, a jar of pasta sauce is good basically indefinitely, but as soon as you actually open the jar the clock starts ticking. We don't make enough pasta at a time to use a full jar, (and in fact will usually use a small fraction of the jar) so I write the date that I opened the jar on the lid to plan its use a little better. "Hey, better find a use for this sauce, it's going to go bad eventually."
Comment · 1 year ago
Inversely, I've also seen promotions where the gallon is heavily featured in the ads, and they're selling the half gallon for full price. Neat, you're paying extra to get less milk!
Comment · 1 year ago
Grade school for me - teachers would say "8.5x11" instead of "letter size" or even just "printer paper." I don't know why they did it, and I assume it's for the same reason that I say it too. It's probably what their teachers said to them!
Comment · 1 year ago
You can always play in tournaments to figure out where you rank compared to a larger population!
Comment · 1 year ago
I don't know about his Spanish Scrabble performance, but when he won the French Scrabble championship, there were players who attempted the French equivalent of "play salirás and see if he notices," and Nigel challenged all of them.
Comment · 1 year ago
I just flew through there, it's wonderful.
Comment · 2 years ago
For me, its finest purpose is to be a buffer that I can paste formatted text into so that it can strip the formatting. There are many programs that do this natively, but there are many that don't or are really inconsistent about the hotkeys, and Notepad is always there.
Comment · 3 years ago
Yep, I grew up in the woodsy part of Framingham up by Route 20. A whole bunch of those roads are outright dangerous. My parents groused about how dangerous it was, but mostly trusted me not to be stupid.
Comment · 3 years ago
Note that in OCaml, you can't get too screwy with point-free programming because of the value restriction. It is possible to compose functions in a point-free manner, but those functions themselves have to have points if you want them to be generic. Standard example:

    let last xs = List.fold_left (fun x y -> Some y) None xs
This is of type

    last : 'a list -> 'a option = <fun>
Neat, `'a` is generic. Let's η-reduce out the `xs` and make the function point-free (ignoring the lambda):

    let last = List.fold_left (fun x y -> Some y) None
This doesn't work the way that we want:

    last : '_weak1 list -> '_weak1 option = <fun>
The moment that we call this weakly polymorphic function, its type is fixed and is no longer generic. In the toplevel:

    # last [1;2;3];;
    - : int option = Some 3
    # last['x';'y';'z'];;
    Error: This expression has type char but an expression was expected of type
             int
Haskell, of course, is totally happy to let you do point-free mania with Kleisli arrows and all of the rest of it.
Comment · 3 years ago
You'll like the `std::ranges` library that's been somewhat implemented as of C++20 and is getting some more stuff in C++23. It's very Fun!

    #include <ranges>
    #include <numeric>
    #include <vector>
    #include <iostream>

    int main() {
        std::vector<int> vec = {1, 2, 3};

        // map, using `std::views::transform`. Implemented in C++20
        for(int elem : 
                std::views::transform(vec, [](int x) { return x + 1; })) {
            std::cout << elem << " "; // 2 3 4
        }
        std::cout << "\n";

        // `std::ranges::fold_left` will be available with C++23.
        // Until then, we're stuck using the <numeric> iterator version, which was
        // implemented in C++20.
        std::cout << std::accumulate(vec.begin(), vec.end(), 1, 
                                     [](int x, int y) { return x * y; }) 
                  << "\n"; // 6

        return 0;
    }
Building and running with the following:

    $ g++ --std=c++20 test.cpp
    $ ./a.out
    2 3 4
    6

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton