4 ms·
It's very cool, but it's also a shame that measuring in characters leads to the metagame of using 97 multi-byte Unicode characters that decode to 194 ASCII char
by amiga386 10mo ago
It's very cool, but it's also a shame that measuring in characters leads to the metagame of using 97 multi-byte Unicode characters that decode to 194 ASCII characters when reinterpreted. Almost everything is in the format:
eval(unescape(escape`<<97 wide characters>>`.replace(/u../g,'')))
Can't they just have the same agreement that Ford Prefect had with Mr Prosser? "So, assuming I'm going to use this lossless compression technique to fit 194 characters into a 140 character tweet... how about you just show the 194 characters and say that I fitted into 140 characters?"
I suppose you could make the same argument about size-based competitions at demo parties; the limit is strictly 4096 bytes but everyone + their dog is using Crinkler to compress a 12-20KB executable down to that size. In fact, part of the effort is in aligning data and tweaking constants with Crinkler's algorithm in mind, to make the raw data more amenable to compression! But at least then, it's not a constant compression (turning any 194 ASCII characters into 97 Unicode characters which with embedded decoder makes exactly 140 characters)
- fainpul 10mo agoOr simply set the limit in bytes (e.g. 140 bytes of UTF8 encoded text).
- jonahx 10mo agoThis is the standard (for good reason) in code golf.
- musicandpiss 10mo agothanks for introducing me to code golf.-)
- jodrellblank 10mo agoSee also: https://code.golf/ https://code.golf/ for a relatively recent gamified site with rankings
- lencastre 10mo agothis is so good
- anonzzzies 10mo agoNice niche golfing languages as well for your continued entertainment!
- cindyllm 10mo ago[dead]
- nightpool 10mo agoif you switch to the beta frontend it has a "compressed" toggle that will do exactly what you're looking for: https://beta.dwitter.net/top https://beta.dwitter.net/top
- amiga386 10mo agoThat's awesome! That's exactly what's needed.
- dang 10mo agoWe've changed to that URL above from https://www.dwitter.net/top https://www.dwitter.net/top. Thanks!
- tomtomtom777 10mo agoNice; a way to also show the actual wrapping code would be nice. I am assuming c is set to a canvas element and x is set to the context, but I can't find actual information on this.
- musicandpiss 10mo agoI have been using Hacker News for 20 years now and this comment is already topping the all time charts of replies.-)
- layer8 10mo agoTo be fair, 140 bytes (1120 bits) corresponds to 160 ASCII characters, or even 170 characters if you exclude control characters.
- lukebechtel 10mo ago(sidebar) love to see a subtle, applicable HHG ref :)