Deebster

joined 2 years ago
[–] Deebster@programming.dev 2 points 1 day ago

Yeah, it's quite a mean trick really - kinda a big middle finger to anyone who does TDD

[–] Deebster@programming.dev 2 points 2 days ago (1 children)

Are words in a poem lyrics?

[–] Deebster@programming.dev 4 points 2 days ago* (last edited 2 days ago) (2 children)

Mild spoilers ahead, but you're reading the solutions thread.

I was just doing some preliminary checking of the data on my phone with Nushell (to see how much my ageing laptop would suffer) when I discovered there weren't any non trivial cases.

Normally I get the test data working before trying the input data, this is definitely teaching me the value of investigating the data before heading down into the code mines.

Unfortunately I can't get the second star yet because I missed a few days.

[–] Deebster@programming.dev 3 points 2 days ago (1 children)

Sounds like perhaps unified codes would be the answer to that problem!

[–] Deebster@programming.dev 4 points 2 days ago* (last edited 2 days ago) (3 children)

Interesting stuff, thanks for writing it up.

I did know that US codes weren't standardised, partially because the video covers it - perhaps I should have phrased it as "a police code" to be more technically correct. Edit: or bothered to check the video so could have written "Philadelphia police code" - but then I would have missed out on your reply.

[–] Deebster@programming.dev 21 points 2 days ago (1 children)

If you read the article, you learn that the authorities never properly searched any of these freighters - that's probably a more sensible place to start.

[–] Deebster@programming.dev 15 points 2 days ago* (last edited 2 days ago) (16 children)

https://www.youtube.com/watch?v=laZpTO7IFtA is worth the 15 minutes, but the TL;DW is that the kids are just using it as an in-joke marker (i.e. the phrase is a shibboleth), but its origin is in lyrics* by the rapper Skrilla referring to police codes for a dead body.

* are rapped words lyrics?

[–] Deebster@programming.dev 2 points 2 days ago* (last edited 2 days ago)

nushell

I'm still travelling, so another phone attempt. Jet lag says sleep, so just part 1 for now:

def part1 [filename: string] {
  mut input = open $filename | lines |
    each { parse '{index}: {children}' | update children { split row " " } | first } |
    insert paths { null }
  print $"Data loaded, ($input | length) devices"

  $input = explore-path $input you
  $input | where index == you | get 0.paths
}

def explore-path [devices, start: string] {
  print $"Exploring ($start)"
  let dev = $devices | where index == $start | first
  if ($dev | get paths) != null {
    print "Already explored"
    return $devices
  }

  # Shadow with mutable version
  mut devices = $devices
  mut paths = 0
  let is_out = $dev | get children | where ($it == out) | is-not-empty
  if $is_out {
    print $"Found an out device: ($start)"
    $paths = 1
  } else {
    for child in ($dev | get children ) {
      $devices = explore-path $devices $child
      $paths += $devices | where index == $child | get 0.paths
    }
  }

  # Shadow with immutable... wtf
  let paths = $paths
  print $"Setting paths for ($start) to ($paths)"
  $devices = $devices | update paths { |row| if $row.index == $start {  
$paths } else {} }
   $devices
}
[–] Deebster@programming.dev 13 points 4 days ago (2 children)

Firefox does seem to be clearing out their old bugs (another example is MKV support) but perhaps it's buses arriving together and not due to some policy.

[–] Deebster@programming.dev 2 points 5 days ago (3 children)

I can't code today because of travel, just as the one that might run slow enough to geek out on benchmarking the various options. Does seem like it's a bit of a jump in difficulty from previous days.

[–] Deebster@programming.dev 15 points 5 days ago* (last edited 5 days ago)

We’re still preparing the notes for this release, and will post them here when they are ready. Please check back later.

Oh come on guys

edit: they're up now

 

I think you fellow solvers will find this talk interesting. There's a few minutes of the usual who am I and what is AoC but there's some good stuff about growing pains, the puzzle design process and why he likes to throw in a hard puzzle in an early day.

edit: bah, I see it was already posted - the Lemmy search doesn't seem to find it unless you limit the search to URL...

 

I'm gutted to hear this - I'm a big fan of Crucial memory and SSDs and all of my systems have at least one thing from them.

Micron will keep shipping Crucial products until the end of February 2026 and provide “continued warranty service and support.”

So only a few month left, plus however long they stay on retailers' shelves.

 

REUNION October 22, 2025

I solved it in 1️⃣6️⃣ moves!
⭐ ⭐ ⭐ 🦊 🦔 🎉

 

This is old news, but no-one posted it at the time.

They released a bunch of new features, including error boundaries, each without as (simple but useful), exported snippets and er LLM-friendly documentation.

There's 24 new things in total, as it was a Christmas advent thing.

219
submitted 10 months ago* (last edited 10 months ago) by Deebster@programming.dev to c/xkcd@lemmy.world
 

Title text:

Can you pass the nackle?

Transcript:

[Cueball is holding a pointer and gesturing towards a whiteboard that shows the chemical formulas HCOOH and CH₃COOH. Below these, respectively, are classic diagramatic representations of formic/methanoic acid [with an apparently accidental doubled bond between the carbon and the hydroxy group] and acetic/ethanoic acid; being, in turn, a single- and double-carbon chain molecule with a double-bonded oxygen (carbonyl group) plus an oxygen-hydrogen (hydroxy) upon one carbon of each, to form the full carboxyl grouping, and hydrogens completing all other expected bonds.]
Cueball: The two simplest carboxylic acids are hakoo and chuckoo.
Off-panel voice: No!!

[Caption below the panel:]
How to annoy chemists

Source: https://xkcd.com/3040/

explainxkcd for #3040

 

Let’s discuss tasks, contestants and the show in general.

Spoilers ahead.

102
Animal Far (infosec.pub)
submitted 1 year ago* (last edited 1 year ago) by Deebster@programming.dev to c/memes@feddit.uk
 
 

Let’s discuss tasks, contestants and the show in general.

Spoilers ahead.

 

cross-posted from: https://programming.dev/post/21363946

The normal complaint new Zellij users have is that it has a lot of keybindings which are likely to conflict with programs like nvim or Helix that use a lot themselves. Before, the workflow was to lock Zellij with ctrl-g which let input go through to the focused shell/program.

The new mode has most of the keybindings behind the ctrl-g lock, e.g. a new tab is ctrl-g t n (instead of ctrl-t n). You can still use alt-(cursor) for changing focus and alt-n/alt-f for a new tiled/floating pane, but all other key presses get passed along.

You can switch between default and unlock-first (non-colliding) modes so if you need those alt shortcuts you can lock everything as before.

Plus some other nice features like being able to change modifier keys while running (via the Kitty Keyboard Protocol), and autoloading the new config when you edit the file.

 

The normal complaint new Zellij users have is that it has a lot of keybindings which are likely to conflict with programs like nvim or Helix that use a lot themselves. Before, the workflow was to lock Zellij with ctrl-g which let input go through to the focused shell/program.

The new mode has most of the keybindings behind the ctrl-g lock, e.g. a new tab is ctrl-g t n (instead of ctrl-t n). You can still use alt-(cursor) for changing focus and alt-n/alt-f for a new tiled/floating pane, but all other key presses get passed along.

You can switch between default and unlock-first (non-colliding) modes so if you need those alt shortcuts you can lock everything as before.

Plus some other nice features like being able to change modifier keys while running (via the Kitty Keyboard Protocol), and autoloading the new config when you edit the file.

 

Let’s discuss tasks, contestants and the show in general.

Spoilers ahead.

 

Let’s discuss tasks, contestants and the show in general.

Spoilers ahead.

view more: next ›