Tenth Post!
Sep. 14th, 2024 06:09 pmI TAKE IT BACK, GO BACK TO FUCKING THE HOUSE!
(https://secretfanspace.dreamwidth.org/2511.html?thread=3560655#cmt3560655)
Welcome back! Chat fandom, weird internet stuff, creative work, games, books, anything! Meme listens, and sometimes even replies!
(start a comment thread by replying to this post)
(https://secretfanspace.dreamwidth.org/2511.html?thread=3560655#cmt3560655)
Welcome back! Chat fandom, weird internet stuff, creative work, games, books, anything! Meme listens, and sometimes even replies!
(start a comment thread by replying to this post)
Re: Coding
Date: 2024-12-04 09:07 pm (UTC)Re: Coding
Date: 2024-12-04 10:48 pm (UTC)I finally did day2. turns out that if you do list.remove[i], that doesn't remove the thing at index i, it removes the first thing in the list matching the value at index i. +_+ Am deceased. Changed it to pop() after fucking HOURS, got my star; learn from my error, o innocent youth
Re: Coding
Date: 2024-12-04 10:52 pm (UTC)Re: Coding
Date: 2024-12-04 11:03 pm (UTC)now listen here u little
but anyway, the way this happens is simple. you don't start off with list.remove(list[i]) . you try a few variants and get syntax errors until you blunder your way into list.remove(list[i]), or if you're really lucky, list.remove(list[:][i]). at this point, it seems to work, and you're so relieved you don't even notice how fucking stupid your code has got. Then, it silently almost-works, for hours. Your test input works. The part 1 input works. Your part 2 answer looks plausible, but the website disagrees. You cry. Your friend finishes and goes off to do fun stuff. You can't figure out why the computer hates you. You're nice to the computer. You give it more attention than anyone else in your life. Why is it LIKE this?
plus i hate pop() because it returns the removed element and that always catches me out because i expect it to be like " X = 'abcde', Y = X.pop('d'); Y is 'abce'", but no, Y is 'd'! X has changed value! I hate it when things change value without being explicitly set to a new value!
Re: Coding
Date: 2024-12-04 11:09 pm (UTC)Though you should see my friend's day 4 solution. I did it the easy (albeit inelegant) way. Friend didn't see how to do it easily, so went on an adventure involving regexps and even perl! He doesn't even KNOW perl; he was like 'I searched the internet, and it was the only thing that knew how to do what I needed'. The way he treated his input reminded me of the way a CRT TV screen works. It took him hours. He got the right answer. He just about wanted to cry when I showed him how I did it. xDDDD