Spyke

Replies

Comment on

Javascript is the most popular scripting language in use today

Reply in thread

The line breaks haven't worked, here's it formatted correctly:

Explanation: it's mostly due to how js does type conversion.

For the Ls, it's:

  • [] is an empty array
  • ![] is treated as false
  • combining a boolean with the empty array returns "false" as a string (so true + [] = "true", false + [] = "false")
  • ! + [] is treated as true
  • ! + [] + ! + [] is treated as 2 since true + true = 1 + 1 = 2
  • so you have "false"[2], which is l

for the o it's:

  • [] is an empty array
  • [] + {} returns "[object Object]" as a string ({} + [] returns 0)
  • ![] is false
  • !![] is true
  • +!![] casts it to an integer
  • so that part is "[object Object]"[1], which returns "o"-

Comment on

Unlimited Kagi searches for $10 per month | Kagi Blog

I've been using Kagi for two months and I'm loving it - the ability to control your results is amazing. Some things I do:

  • remove or downrate things like pinterest and w3schools from my results
  • rewrite www.reddit.com/* to old.reddit.com/*
  • rewrite to send some sources through archive.today or similar to break paywalls
  • rewrite to set the language of some sites that GeoIP my location but ignore my language headers

Also, having keyboard controls - like Google used to have - is so welcome, and their AI summarisation tools are actually useful too.

canvas

Comment on

Suggestions for Canvas 2024 (or any future events)

Reply in thread

That's true, but one thing I liked about r/place was the evolution of designs - for example a massive flag would appear early on, be fought over and then the flag would shrink to a more defensible size and the rest of the flag became a different thing. The time lapse was fascinating because of this.

The culture here is more cooperative and less troll-y (trollful? trollesque?) so I'd hope/expect to see more collaborative solutions. I know once I'd helped place the fuck cars logo I threw my pixels into helping build unfinished designs or repair existing ones.

canvas

Comment on

Pixels Placed per Instance

Thanks for this, now I’m interested in all the other stats, like number of users per instance, %age of instance users per instance, # surviving pixels, %age pixels surviving, overall heatmap (esp. most fought over area), chart of cumulative placements over time, etc.

Comment on

YSK: There's a website with seemingly never ending offers on VPS.

They do seem almost too good to be true. I might use those for when I want lots of little, disposable servers (like regional game servers) but I'd be scared trusting critical stuff to them.

On the other hand, https://lowendtalk.com/ users seem to have rated them highly (not that I'd heard of that site before today either!).

Overall, definitely worth the risk at that price, thanks for the heads up.

rust

Comment on

SerenityOS author says Rust is OO-hostile

He does, but the title makes it sound like he's criticising when he's just explaining some context.

He says they write their engines to be closely modelled on the specs, and that the web and the web spec is an object-oriented platform.

When asked if he'd use another language for Ladybird he first answers Swift - well actually he first jokes that he'd first design a new language, then says that he looked at Rust and likes a lot of things about it. When asked about why-not-Rust he says he likes OO languages and this project should be in an OO language because so is the spec, and Rust is not OO-friendly, “it's, like, OO-hostile”.