[-] snowe@programming.dev 4 points 2 years ago

that post is about toggle buttons, not switches. e.g. a play pause button, when pressed, does it show play, or does it show pause?

[-] snowe@programming.dev 4 points 2 years ago

I thought it was adblocks latest update.

[-] snowe@programming.dev 4 points 2 years ago

You don’t need to be young to have not wanted to watch. I’m glad I never watched past the first thirty minutes of the first episode. Saved me a lot of time down the line.

[-] snowe@programming.dev 4 points 2 years ago* (last edited 2 years ago)

Ruby

!ruby@programming.dev [LANGUAGE: Ruby]

I found today really easy thankfully. Hardest part was remembering the language features haha

https://github.com/snowe2010/advent-of-code/blob/master/ruby_aoc/2023/day09/day09.rb

edit: code golfing this one was easy too! man this day really worked out huh

    def get_subsequent_reading(reading)
      puts "passed in readings #{reading}"
      if reading.all?(0)
        reading << 0
      else
        readings = reading.each_cons(2).map do |a, b|
          b - a
        end
        sub_reading = get_subsequent_reading(readings)
        reading << (reading[-1] + sub_reading[-1])
        puts "current reading #{reading}"
        reading
      end
    end
    
    execute(1) do |lines|
      lines.map do |reading|
        get_subsequent_reading(reading.split.map(&:to_i))
      end.map {|arr| arr[-1]}.sum
    end
    
    
    def get_preceeding_readings(reading)
      puts "passed in readings #{reading}"
      if reading.all?(0)
        reading.unshift(0)
      else
        readings = reading.each_cons(2).map do |a, b|
          b - a
        end
        sub_reading = get_preceeding_readings(readings)
        reading.unshift(reading[0] - sub_reading[0])
        puts "current reading #{readings} #{sub_reading}"
        reading
      end
    end
    
    
    execute(2, test_only: false, test_file_suffix: '') do |lines|
      lines.map do |reading|
        get_preceeding_readings(reading.split.map(&:to_i))
      end.map {|arr| arr[0]}.sum
    end

code golf

  a=->r{r.unshift(r.all?(0)?0:(r[0]-a[r.each_cons(2).map{_2-_1}][0]))}
  l.map{a[_1.split.map(&:to_i)]}.map{_1[0]}.sum
[-] snowe@programming.dev 4 points 2 years ago

Oh no I have to mod a config file to make it do what I want…why can’t the devs just read my mind???

nobody has to read anyone's fucking mind, why can't you just make it a fucking settings menu? You're the ones making it HARDER TO EVANGELIZE FOSS. For fuck's sake! You're entirely missing the point!

[-] snowe@programming.dev 4 points 2 years ago

I have an Ioniq 5 limited awd and the range is great. I don’t know what people are doing that they need 300+ miles of range every day, but it charges in minutes, overnight with a 120, and I haven’t once felt any range anxiety.

[-] snowe@programming.dev 4 points 2 years ago

This is common because of the term Software Developer but the developer part of game developer comes from the creation/construction side

since when? When did the software part of game developer stop being about actual code development and start being more like property or community? That makes literally no sense at all. Developer as it relates to any sort of code means the person actually writing the code. To say otherwise is just ignoring the meaning of words.

[-] snowe@programming.dev 4 points 3 years ago

Could you explain this more?

[-] snowe@programming.dev 4 points 3 years ago

You can get some bad bugs due to the fact that white space is significant, not because you are using it. For example how is the IDE supposed to know when you’re done writing your if statement? Or done with a loop? It’s impossible. It’s pretty telling that Python is the only language on this list that has significant white space.(somebody please check me on this, but I’m pretty sure I didn’t miss anything here).

[-] snowe@programming.dev 4 points 3 years ago

Or there’s Safari or Orion, neither of which are what you listed. Also, Firefox is not “paid for by google” they get funding through their nonprofit as well.

[-] snowe@programming.dev 4 points 3 years ago

That statement is just outright wrong though. They could easily use CloudFlares CSAM monitoring and it never would have been a problem. A lot of people in these threads, including admins, have absolutely no idea what they’re talking about.

[-] snowe@programming.dev 4 points 3 years ago

But you can. Just cut a hole in the bottom and eat it from there. Then it’s presentable and edible.

view more: ‹ prev next ›

snowe

0 post score
0 comment score
joined 3 years ago
MODERATOR OF