Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
PeCaN
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
105 ms
·
931.
▲
by
PeCaN
11y ago
That seems like a bit of a stretch. Who's to say strong AI will even be significantly smarter than us anyway? What if humans are almost as smart (obviously there's some room for improvement) as it's physically possible to be?
932.
▲
by
PeCaN
11y ago
Social awareness? I'd be interested if you elaborate, what makes them more "socially aware" than any other culture? What do you think about the alleged xenophobia? Personally I'd love to visit Japan sometime.
933.
▲
by
PeCaN
11y ago
I think (?) Scala has proper monads (but they're a little weird) which would let you avoid the verbose extra code. Generally it just involves implementing map and flatMap on your Either type, or something like that. Disclaimer: not a S
934.
▲
by
PeCaN
11y ago
Did that in the US in the mid 2000s, though spent hardly a week on either IIRC. Something like base 20 Mayans, base 60 Sumerians, and base 2 computers. Do math in each and convert them to/from base 10. I think that's been dropped
935.
▲
by
PeCaN
11y ago
Even back then I'd always use at least double-ROT13, only one iteration was brute-forced on even consumer abacuses pretty easily.
936.
▲
by
PeCaN
11y ago
Why's this downvoted, it seems like useful advice to me. Also cffi is definitely awesome.
937.
▲
by
PeCaN
11y ago
Marginally off-topic, but Minix 3.3 runs the (almost) complete NetBSD userland now. To use X11 you have to compile the development branch, however. It's a real, POSIX-compliant, reliable microkernel that can run useful things now.
938.
▲
by
PeCaN
11y ago
Nearly all the syntax ambiguities I've had in Ruby were resolved by either adjusting some whitespace or adding parens, and neither make the code any more difficult to read. In my experience Ruby is easy enough for humans to parse (real
939.
▲
by
PeCaN
11y ago
That's what a lot of JIT compilers do. SpiderMonkey for example does type inference in the interpreter (or baseline JIT? what do they use now) and uses that to generate almost exactly what you're describing. If the type inference
940.
▲
by
PeCaN
11y ago
Pretty sure IBM and AMD are both partnering with Xilinx, they're not going anywhere any time soon. (Plus they also have more enterprise contracts than Altera does.)
941.
▲
by
PeCaN
11y ago
Theoretically yes (Intel does support OpenCL in their iGPU drivers), but performance will be mediocre at best. Faster than CPU hashing though.
942.
▲
by
PeCaN
11y ago
For LZ algorithms, the dictionary made when compressing the first version would be reused for subsequent "versions" of the same document. So sort of a static dictionary, but specialized for what you're sending. That or maybe
943.
▲
by
PeCaN
11y ago
AFAIK most of them use some blend of edit distance (usually a modification of Levenshtein distance to support transpositions) and often a phonetic algorithm like Soundex[1]. Dictionaries are most often stored as a radix trie, and a bloom fi
944.
▲
by
PeCaN
11y ago
Just transform it to continuation-passing style[1] and call/cc is no problem (neither are non-local exits). Granted your compiled code will be somewhat large and not much like 'regular' code in the language. That can be solve
945.
▲
by
PeCaN
11y ago
For playing around with languages I'd actually recommend writing your own lexer and parser. It isn't hard, and writing a recursive descent parser really helps understanding grammars and BNF. Before you have a solid grasp of how co
946.
▲
by
PeCaN
11y ago
I would argue that it's easier to understand short, even excessively terse, code than it is to understand long code. I can look at a few lines of Haskell and even though deciphering it may take me some time, the cognitive overhead of a
947.
▲
by
PeCaN
11y ago
Heh, that's where it is on mine too. :) One of the things I find particularly nice about GLL is that it's much more friendly to parser combinators[1] than GLR. (LR-family parsers, and bottom-up parsing in general, is notoriously d
948.
▲
by
PeCaN
11y ago
Generalized LL Parsing - http://dotat.at/tmp/gll.pdf Parse ambiguous context-free grammars in worst-case cubic time and unambiguous grammars in linear time, with an intuitive recursive-descent-ish algorithm. GLL is the
949.
▲
by
PeCaN
11y ago
The NSA/GCHQ/etc could crack a random person's attempt at "encryption" in hours. Even if they were to use AES or some other algorithm that actually works, getting end-to-end encrypted messaging right is hard .
950.
▲
by
PeCaN
11y ago
Evidence? As far as I can tell the only 'fraudulent' thing they did was jump to the conclusion of "WE MADE ENERGY WITH COLD FUSION" when they probably should've announced their result with "looks like we have s
951.
▲
by
PeCaN
11y ago
It's not in any way a physical limitation that Dart is slower than Java. It's just somewhat harder to make fast, and even then, some of Dart's design is motivated by being able to implement the language efficiently. [1] Dart
952.
▲
by
PeCaN
11y ago
No! Use a proper key-derivation function (bcrypt, scrypt, pbkdf2), not a hash function. SHA family, including the rather unrelated but exceptionally nifty SHA-3 (Keccak), are still hash functions and are still really fast to compute (good i
953.
▲
by
PeCaN
11y ago
Dart's performance is pretty good; its authors are VM geniuses. If it doesn't already[1], it could leverage the optional typing for block versioning on initial compilation, and assume that version is correct most of the time (gene
954.
▲
by
PeCaN
11y ago
I think that 'iTerm2' in the corner is just the name of the currently focused window.
955.
▲
by
PeCaN
11y ago
Dart always seemed like it was better suited for Android development than for web applications. Snapshots work particularly well, since the OS could manage persistence basically for free.
956.
▲
by
PeCaN
11y ago
Woah, that's very useful. Might even be your killer feature, actually. Totally checking this out.
957.
▲
by
PeCaN
11y ago
Personally I just consider that uglier. Also you can parse var i: Int = 1 unambiguously without backtracking, while you have to backtrack on var Int i = 1 (unless you enforce some constraint like type names must start with capitals, in whic
958.
▲
by
PeCaN
11y ago
Well, PHP is certainly efficient for programming websites. It just comes at the expense of everything else. Yes, bashing PHP is fun, and yes, I do it all the time. PHP may be a joke, but there are a bunch of PHP websites because PHP is a v
959.
▲
by
PeCaN
11y ago
Actually, English has a fairly high entropy/syllables ratio. [1][2] Also, given that we can infer with decent accuracy what people are saying even in noisy environments, I would say it's really not too bad. You could do better of
960.
▲
by
PeCaN
11y ago
Do you use evil-mode? I went the opposite direction (Emacs -> vim -> now kak[1]), and I find non-modal editing quite frustrating now. 1: https://github.com/mawww/kakoune
More ›