#advent-of-code

1 messages ยท Page 24 of 1

stable shale
#

I forgot that AoC was today F_

woven scaffold
#

One can write code in the fast cp style way and also be able to write good clean readable code in other places

night berry
#

these madlad got it

karmic sequoia
#

yeah, but in real life, good code style is almost as important

slender ravine
#

Time to go back to sleep

karmic sequoia
earnest forge
#

50/51, tied 42nd global

night berry
woven scaffold
sullen adder
earnest forge
#

I would argue that overuse of OOP abstraction is bad programming habits and code style

karmic sequoia
twin widget
sullen adder
#

how do some of y'all even process the problem that fast โ˜•

karmic sequoia
karmic sequoia
#

anyway day 1 done

night berry
#

yea, skip the fluff

woven scaffold
karmic sequoia
karmic sequoia
vestal kelp
#

Hey ๐Ÿ˜†

karmic sequoia
#

you're incentivized to code fast, not code well

earnest forge
karmic sequoia
#

sure, but it isnt within the scope of what was discussed

#

i need to go now baiii

slender ravine
#

Tbf, how long it took for leaderboard to fill up

#

For this one

gentle cape
#

i did the first problem

#

do we have a leaderboard

slender ravine
normal dragon
#

Here's the truth about competitive programming and good coding style: you can have fun doing competitive programming and be a professional programmer with good code style and more

slender ravine
#

It gives you the instructions

wary river
#

I'm about to drop the most noob-looking, stupid sounding question ever heard of on advent of code
where can I find the problem statement

normal dragon
#

Part of the 'challenge' of AoC is learning how to decode the strange story instructions into what you actually need to do.

wary river
#

i can't find it ๐Ÿ˜ญ

#

i can't find anything, I can only find about the advent of code itself

slender ravine
slender ravine
#

Or this ^

#
  • logging in
slender ravine
wary river
slender ravine
#

Competitive require fast and accurate logic thinking

karmic sequoia
#

lesgo im 14th place

gentle cape
#

So that the first line of input isnโ€™t the number of inputs ๐Ÿ˜ญ๐Ÿ˜ญ๐Ÿ˜ญ

#

Why canโ€™t they just be like codeforces

karmic sequoia
gentle cape
normal dragon
slender ravine
wary river
gentle cape
#

I never use globals when Iโ€™m doing usaco problems

woven oriole
karmic sequoia
slender ravine
gentle cape
karmic sequoia
gentle cape
#

Also I admire those people

normal dragon
#

And if they end up getting a job as a professional programmer, then they're going to have to learn a whole new bunch of skills.

slender ravine
#

Imagine getting beat by people that ain't even going to be a professional programmer ๐Ÿฅด

hollow summit
#

we up

gentle cape
#

They manage to type out a200 line algorithm in one go using only single letter variable names

hollow summit
#

chat we up

humble copper
#

Miserable performance today (8 mins)...

gentle cape
#

I wish I had that mental capacity

hollow summit
karmic sequoia
karmic sequoia
humble copper
#

if i somehow manage to complete all of them this year ill be surprised

hollow summit
hollow summit
#

is that global lb

gentle cape
#

Thatโ€™s wild

karmic sequoia
gentle cape
#

Leave it to some random dude from China

hollow summit
karmic sequoia
#

i'm 5000th place global

karmic sequoia
magic scaffold
#

deleted the whole ass repo lol

gentle cape
slender ravine
#

I wonder they would get ban by aoc, but doubt tho

karmic sequoia
#

Please don't use AI / LLMs (like GPT) to automatically solve a day's puzzles until that day's global leaderboards are full. By "automatically", I mean using AI to do most or all of the puzzle solving, like handing the puzzle text directly to an LLM.
chat

gentle cape
#

I brute forced subproblem 2 lmfao

slender ravine
#

Yeah, I remember that so ye

gentle cape
#

I did not want to do the O(n) solution

karmic sequoia
gentle cape
#

Sorry wait

#

I donโ€™t think O n is possible

karmic sequoia
#

wait guys

#

O(log n) is possible for this question

gentle cape
#

O(n log n) for part 2

karmic sequoia
#

yeha

gentle cape
#

I think thatโ€™s the smallest you can get

#

Sort and then use two pointer

#

For the first part itโ€™s also basically the same

#

Sort and then traverse

magic scaffold
gentle cape
minor cave
#

I'd like to remind y'all that this channel has a fairly strict no spoilers policy

magic scaffold
#

wait no

karmic sequoia
#

you can do O(n) where n is the size of the output for part 1 and 2

send answers to aoc and use timing to binary search the answer

slender ravine
#

||Why would it not possible for O(n)||

gentle cape
#

It is

karmic sequoia
#

it is possible

gentle cape
#

I just didnโ€™t think of it

#

I do too little leetcode

karmic sequoia
slender ravine
gentle cape
#

Chat Iโ€™m not passing usaco this year ๐Ÿ˜ญ๐Ÿ˜ญ

magic scaffold
karmic sequoia
#

lmao

karmic sequoia
#

"oopsies uwu :3" type shit

slender ravine
#

Also maybe not public the solution? Lmao ๐Ÿฅด

earnest forge
magic scaffold
slender ravine
peak dock
#

putting it on github is crazy

mortal bronze
#

Uhm guys you think I can participate??? Look on my GitHub for assessment....

slender ravine
magic scaffold
#

what has GH got to do with AOC, lol i remember solving some problems with pen and paper lol

slender ravine
#

You can solve previous question anyway, maybe he tried them

cyan sleet
#

vim is done

#

perfect run script

vim input -esS main.vim -c 'call Part1() | q!' && cat part1
vim input -esS main.vim -c 'call Part2() | q!' && cat part2
#

ooh, this is actually better, no output file needed

vim input -esS main.vim -c 'call Part1() | :%p | q!'
vim input -esS main.vim -c 'call Part2() | :%p | q!'
vagrant gorge
#

who summoned

remote beacon
#

That was fun

modern terrace
#

i forgot about aoc :p

cyan sleet
mossy basin
brittle cairn
mossy basin
#

that is not a challenge for me

#

i'll stick with terminal visualizations

magic oxide
#

fenix what editor are you using throughout all the languages?

#

I assume neovim but thought I'd ask

karmic sequoia
mossy basin
#

challenge for @lusty rover

magic scaffold
mossy basin
#

not a good day for a visual

#

i guess i could show actually searching through the list, but i'm probably not gonna do that

magic scaffold
#

bruv we get it that, you got a new fade

#

to me? no

crimson marsh
#

is this advent of code related?

wary river
#

imo shave the neck beard

crimson marsh
#

again, is this related to advent of code?

maiden ginkgo
#

This isn't related to coding at all

signal copper
#

<@&831776746206265384> something kinda fishy is happening

ocean karma
somber trench
somber trench
#

ah, that kind of pole

long egret
#

!cban 855827898141114368 troll

marsh currentBOT
#

:incoming_envelope: :ok_hand: applied ban to @misty moat permanently.

somber trench
#

now we wait for day 2 which is going to be 10x harder lol

pulsar heart
slate berry
#

Heyyy im back for another advent

slate berry
#

any solutions for today's aoc without ||sort||

hollow wharf
#

ive been waiting a year for this event ๐Ÿ”ฅ

molten fulcrum
#

Hmmm I wonder, maybe itโ€™s time to solve AoC in Vue? Should make for some interesting visualizations

limpid grail
#

what does this first line mean?

#

is it the start of some diagram

hollow wharf
#

yes

#

this is for example last year

limpid grail
#

ohhh

#

what is that

#

a bonsai christmas tree?

mossy basin
#

floating islands

limpid grail
#

ohh

#

right, the story

#

we're finding the chief!

#

so i guess it'll be some kind of map

#

Speaking of, what are y'all input copying and using workflow?

mossy basin
#

!pypi aoc_lube

marsh currentBOT
limpid grail
#

Nice package!

marsh currentBOT
#

dummy name to pull advent-of-code-data

Released on <t:1607168734:D>.

sullen adder
#

can't believe i got the package name wrong twice ... ๐Ÿ˜ฎโ€๐Ÿ’จ

#

aocd is good as well ๐Ÿ‘ #bot-commands message

hollow wharf
limpid grail
#

I'm going to be using this, making sure I only send one request per day :D


def get_aoc_input(day: int) -> str:
    day = str(day)
    aoc_inputs = read_aoc_inputs()

    if day in aoc_inputs:
        return aoc_inputs[day]

    response = requests.get(
        f"https://adventofcode.com/2024/day/{day}/input",
        headers=AOC_HEADERS,
    )
    aoc_inputs[day] = response.text
    write_aoc_inputs(aoc_inputs)

    return aoc_inputs[day]
#

If you want to get your AOC_HEADERS, go on to the site (make sure to reload it) and inspect it
Then go to the network tab and find the Request Headers

#

Toggle Raw mode, copy that text and ask CGPT to convert that to a Python request header

#

its working great ๐Ÿ‘

hollow wharf
#

and ask GPT
bruh

limpid grail
#

Hey man, if you want to do it yourself go ahead

#

Not me ๐Ÿ˜„

#

But maybe the session cookie alone is enough to get

hollow wharf
#

I fear that one day this AI thing will become good enough that I won't be able to have this kind of reaction anymore because it'll just look stupid lol

limpid grail
#

It probably is, but anyways this works and im low on time

hollow wharf
#

Oh? Why are you low on time

limpid grail
#

I'm doing engineering

hollow wharf
limpid grail
#

we're going to pretend i didnt just not do that

#

umm almost

#

day needs to be used as a str since apparently json cant have ints as keys

#

yeah it works now ๐Ÿ‘

peak dock
#

now make submit

limpid grail
#

i did that a while back by manually copying inputs lol

#

๐Ÿ˜Ž

peak dock
#

no i mean a submit() function

hollow wharf
#

you can make submit the same way you did this

limpid grail
#

bru

hollow wharf
#

auto submit using a request

limpid grail
#

nah i want to feel it

#

i want to see the gold star pop up on my screen

#

i got inspired after i met someone in my uni (after talking with them in the uni discord) and they said they're doing AOC in Rust

#

but im just doing it, for funsies

#

maybe some of them ill optimize if i have time

hollow wharf
#

i know that feeling, its me from a year ago when i did aoc the first time

limpid grail
#

this is my third time trying aoc, i usually just get bored and stop lol

peak dock
#

the most recent activity in my uni discord was three months ago and that was a steam scam post

limpid grail
#

also it gets challenging at some point

limpid grail
hollow wharf
limpid grail
#

yeah maybe i wont be able to solve everything on the same day

#

wait can you do day 1's thing on the next day

peak dock
#

i only finished aoc the first year i did it

peak dock
#

theres no time limit

limpid grail
#

ohh

hollow wharf
#

yeah you can do any year and challenge anytime

limpid grail
#

will i still get stars tho

peak dock
#

yes

hollow wharf
#

yes

limpid grail
#

noice

hollow wharf
#

you just wont be on the leaderboard

#

or just will be so far

peak dock
#

not if you make a private leaderboard with just yourself

#

๐Ÿ˜Ž ๐Ÿ‘

hollow wharf
#

easy 1st place

limpid grail
#

i dont think ill be on the leaderboard anywyas lol

#

if i do compete it'll be for performance

low condor
#

Good morning

hollow wharf
#

hey

limpid grail
#

good morning

hollow wharf
limpid grail
#

nuh

low condor
#

Shall I code in Python or Rust (I ainโ€™t doing the roulette this year) - decisions decisions

thorn inlet
#

do both

limpid grail
#

umm finish in python first

low condor
#

Could do

limpid grail
#

get those stars

#

then do rust

hollow wharf
#

maybe try something except those

naive wharf
#

who pinged

limpid grail
#

if i try rust id learn something

low condor
#

For me this is less about the stars and about doing something new

#

So Iโ€™m going to force myself to always code using Vim modes this month

limpid grail
#

gleam

#

nice

limpid grail
#

yessir

#

purists will be repelled by that day = str(day) ๐Ÿ˜ผ

limber jewel
#

any < 100 rank?

rancid zealot
#

is absolute value needed here?

hollow wharf
#

y

thorn inlet
#

for the "difference" you could use it yeah

rancid zealot
#

ooh

#

like im pure begginer so like i dont even know if my code is right

#

like i wrote all this

#

so do you have any suggestions

hollow wharf
#

also if you want to know if your answer is correct

#

just try

rancid zealot
#

are so any suggestions on thsi?

hollow wharf
rancid zealot
#

ooh ok ok

marble minnow
#

okay what. The question is either worded weirdly or i'm just tired cuz I just woke up

limpid grail
#

you're tired

#

:kek

marble minnow
#

yeah, most likely

limpid grail
#

read the story! its fun

marble minnow
#

i've read it, always do : )

#

could you explain one thing for me please?

#

oh okay

#

i was about to ask my question but then answer came to my mind

ocean grove
#

If I post a workingsolution, is possible for people to provide with tips to optimise my code?

slender ravine
#

should I try vimscript even when I have never used vim

hollow wharf
#

what is even vimscript x)

#

is that like the language to code vim extensions?

slender ravine
#

probably something that automate vim

wheat marsh
low condor
#

Am happy to help you with this when I finish today, if you'd like :)

#

shouldn't take too long - just need to learn rust first

karmic sequoia
#

can't you do aoc part 1 in O(n + log n)

#

answer: no you cant im stupid

low condor
#

I would suggest not posting this in here even for older days.
Do you want to make a thread in #aoc-solution-hints

hollow wharf
#

do people use libraries like numpy in aoc or is it generally just standard libraries only?

low condor
#

do whatever you like :)

#

it's deliberately set up that way

vagrant geyser
#

There have been some problems in the last years that nicely map to a series of matrix transformations, so yeah, numpy works well for some problems

low condor
#

sometimes I use networkx for upcoming path problems

hollow wharf
#

Looking at the first problem it's set up like a matrix from what I can see, so I'm kinda like why would I do matrix multiplication if I can just use numpy

||I'm got the basic logic down using abs but need to order the two columns to compare in order||

#

Nvm, just used ||zip||

karmic sequoia
rapid wolf
bleak sable
#

Tried to one-line in repl, got hit with SyntaxError: assignment expression cannot be used in a comprehension iterable expression :c

rapid wolf
#

classic

karmic sequoia
bleak sable
# rapid wolf classic

To bypass it, used ||(l:=text_parsing_here)and sum(actual_calculation_here) || no semicolon, still one expression :3

rapid wolf
#

noice

bleak sable
# karmic sequoia wgut

If there are no nested loops, just loops next to each other, then it's O(n). Because even O(100n) is O(n)

karmic sequoia
#

O(1)

#

logick 100

bleak sable
#

You gotta find the answer first. See definitions of O, the constant multiplier or lower-O elements of the sum don't matter

chilly willow
#

[redacted]

lusty rover
lusty rover
cobalt roost
#

can you send me an easy beginner code of python for guess the number game

west fractal
cobalt roost
#

help me pls

#

pls

#

pls

#

for god sake]

#

pls

lusty rover
slender ravine
#

Anyone manage to do recursive regex substitution

rapid wolf
lost musk
#

Do I need to be on our private leaderboard to qualify for the AOC completion role at the end?

minor cave
lost musk
lost musk
#

ohh okie thats good ^^

hollow wharf
#

yea?

#

oh sorry

rancid creek
#

woo, hullo!

#

where's the info on joining the leaderboard?

ivory venture
rancid creek
ivory venture
#

hmm

#

I'll check the logs

rancid creek
#

worked when I tried again.

hollow wharf
#

Yeh had the same

brisk briar
#

does anyone have solutions to AoC in languages other than python?

brisk briar
#

oo

hidden pawn
#

in part 2, do they mean how many times a single digit occurs, or how many times that exact number occurs.
for example, with the number 39842: do they mean how many times 3, 9, 8, 4 and 2 occurs in the other list, or do they mean how many times 39842 occurs in the other list?

#

I'm a little confused on the wording ๐Ÿ˜…

peak dock
#

how many times 39842 occurs in the other list
this one

hidden pawn
#

ok! thanks!

unborn bloom
#

hope its fine, anyone who is struggling to learn python, you can DM me.

north lantern
#

Can someone help me with day1(python)?

#

For some reason the result is too high

#

Or do I really need to make it with 2 lists

thorn inlet
#

you could do it with a single list, but uh, you iterate over it in a really weird way, and you sorted the whole list when you should be sorting 2 individual rows
you take the first number, and the rest of them, then the second and the rest, ...

thorn inlet
#

im not sure how did you even end up with this, it just doesnt make sense

north lantern
#

Yeah me neither

#

But how would I fix it

thorn inlet
#

i would recommend to use 2 lists and think a bit more on how to do the iteration

north lantern
#

Oh

ivory venture
north lantern
#

Oh mb

sleek cave
#

when i finished day 1, i glanced up, and as if on cue:

#

(this is our first snow of the winter)
aoc is magical y'all

thorn inlet
#

im waiting for snow so much
its honestly weird to not have it in december. like, it was already there in the start of november, but then the temperature got back to like 4'C so it melted

strange zinc
#

Hallo again everyone ๐Ÿ˜„

hollow wharf
#

Hello

hazy ermine
tepid cairn
#

what helper library are yall using?

#

I think salt had one? I believe that's what I used last year

hollow wharf
crimson marsh
marsh currentBOT
crimson marsh
#

Havenโ€™t tried it myself yet

tepid cairn
#

right yeah, that's what I was using

brisk briar
#

I made a little website to display the community's solutions to AoC questions (here) But according to the AoC about page:

Can I copy/redistribute part of Advent of Code? Please don't. Advent of Code is free to use, not free to copy. If you're posting a code repository somewhere, please don't include parts of Advent of Code like the puzzle text or your inputs. If you're making a website, please don't make it look like Advent of Code or name it something similar.

Should I take the website down? Or is it fine if I provide credit for the design to AoC?

rapid wolf
#

You can have the solutions, but you shouldn't be reposting the puzzles afaik

brisk briar
#

Got it, so I'll just replace the puzzles part with links to the aoc question?

rapid wolf
#

yea, that should be fine

strange zinc
#

nice little site

brisk briar
#

thank you <3

long egret
#

you can just contact them about it iirc they're pretty responsive

halcyon pulsar
craggy maple
#

I'm doing this in random languages every day

#

Today was rust, tomorrow is golang, hoping to land on python one of the days lol

lusty rover
#

We post a random language here

#

Today's was Vimscript

slow sluice
#

I am being serious I am not joking

#

Why lubricant?

low condor
#

I guess cos itโ€™s meant to make coding in AoC moreโ€ฆ frictionless

mossy basin
#

and because it's kinda a funny name

gentle cape
sullen adder
#

how much does the difficulty scale for each day? i found the first day to be fairly straightforward, but i assume they get very tough at some point. pithink

low condor
#

Vimscript wasn't bad to code in actually

#

at least for day 1

low condor
#

still haven't done last years 24 part 2

sullen adder
#

oh wow

lusty rover
#

I think the highest one I've ever made it to is 12

sullen adder
#

i might never get 50 stars ๐Ÿ˜”

lusty rover
#

I sure wont softFeels

low condor
sullen adder
#

wow that is impressive work

lusty rover
#

look at mr richy rich over here

low condor
sullen adder
#

i suppose it is relative... i have 6 total stars ๐Ÿ˜…

low condor
#

if you're learning then it's all good

sullen adder
#

yes of course

low condor
#

also this screenshot reminds me I should renew my AoC++

#

brb

#

There that's much better :)

#

I pay for this and for Nitro - which I need to post my not-so-code golfed solutions in this server

lusty rover
#

lol, !paste

low condor
#

yeah but where's the fun in that

lusty rover
#

Or just link the GitHub where they already are anyways

low condor
#

it's much more fun to make people scroll instead

lusty rover
#

I pay for Nitro just for the emojis

low condor
#

That is also a noble reason

#

I do like having separate profile pics

#

IRL friends sometimes get weirded out by my profile pic decisions on this server XD

lusty rover
#

they can get over it

low condor
#

"Why is your profile pic Elsa?" "That is a difficult thing to explain"

sullen adder
#

is it possible to see completion times for the leaderboard in #aoc-bot-commands? ๐Ÿค”

brisk briar
karmic sequoia
karmic sequoia
lusty rover
#

based

karmic sequoia
#

yeah no im not completing this year

lusty rover
#

me neither

karmic sequoia
#

anyway i might do aoc in class

#

ah welp i have PE no aoc for me

karmic sequoia
lusty rover
karmic sequoia
#

"wait hold up teacher i need to do today's aoc"
"what the fuck is an aoc"

leaden tartan
#

Is the leaderboard ID thing the same for this year?

minor cave
leaden tartan
#

I've somehow ended up in 2

shrewd sentinel
#

just finished day 1

#

i feel

#

proud of myself

#

even tho i had to search some things up

#

it proved to me

#

i do have some tangible problem solving skills

#

heck i got part 2 on the first try

gentle cape
compact wasp
#

i'm back

#

i forgot to do day 1 though despair

rancid creek
shrewd sentinel
#

thx

rancid creek
# shrewd sentinel thx

Make sure you take some time to look at how others solved it and see if you see any new tricks you can pick up.

#

I was reminded of np.loadtxt() yesterday. There's always something new, or something you've forgotten.

compact wasp
#

btw where are the golfers at

glossy terrace
#

huh

floral hare
#

Hello Everybody!

#

20 minutes to go for day 2!

native oak
#

hi guys

#

i need help w python smth

#

anyone on?

shrewd sentinel
native oak
#

so i have a link (my AoC day1 input) with the numbers right, i wanna somehow read the file and then use it to complete my code

#

would it be better to copy paste the data in a .txt file then use that in my code by open() and stuff?

#

sorry, i know im not being clear, im a very bad beginner to python, so I can't prompt properly

floral hare
#

it's not like readable nor good to have per say a 1000 line string variable in your code would it?

compact wasp
#

code files should be used for logic

#

the 1000 line string variable is not that

floral hare
#

also looks like this year there's only like a few people who did the 2nd part?

compact wasp
native oak
#

okay guys thankss

#

stay on im gonna cook :>

compact wasp
#

with a name like inferno you'd better

native oak
#

how do I use github?

#

i wanna create a file for my AoC 2024

#

is that a good idea? how do I create one? (ive only made an account, idk anything else)

floral hare
#

(it's more said about in the about page)

native oak
#

wdym? post it for what

shrewd sentinel
#

im just gonna wait until the month is done

native oak
#

cuz if so, my code is horrible, I dont want anyone using this thing ๐Ÿ’€

floral hare
native oak
#

I dont get what you mean sorry, whats the relation with the lb and github ??

shrewd sentinel
#

they just dont want people posting the solution so that others dont copy it

#

i think

native oak
#

ohh

minor cave
#

We don't want solutions posted in this channel specifically. This is a spoiler-free channel.
The overall Advent of Code policy is that no solutions are to be posted until the global leaderboard fills up.

native oak
#

oh sorry, ill delete my screenshot then

#

im sorry

compact wasp
minor cave
#

You're welcome to post it in our spoilers thread (we have one for each day). If you're looking for help we have #aoc-solution-hints, where you can create a thread there or post more spoiler-y things (just not full solutions there)

earnest forge
#

GLHF everyone

floral hare
compact wasp
#

glhf

minor cave
#

&aoc c

shut trellisBOT
#

Day 2 starts <t:1733115600:R>.

floral hare
#

glhf yall

compact wasp
#

hoping for leaderboard ๐Ÿ™

floral hare
compact wasp
#

i forgot it started yesterday

minor cave
slender ravine
#

< waking up just to do it

compact wasp
#

so i lost a ton of points

#

yes

#

give up

floral hare
slender ravine
#

Lmao ๐Ÿฅด

#

Just retry

compact wasp
#

^

floral hare
#

this is getting exciting

compact wasp
#

i'm about to lose

floral hare
#

anyone here using Neovim?

#

40 Seconds to go!

native oak
#

guys uh which pls help

slender ravine
#

I am just using python to also get input and submit automatically

compact wasp
native oak
#

๐Ÿ˜ข im so clueless and bad everyone so pro here that its discouraging :(

floral hare
compact wasp
#

nah i'm the opposite of pro

native oak
#

uh u mean code editor?

#

Vsc

slender ravine
#

It just loading ๐Ÿฅด

compact wasp
#

lol

tulip elbow
#

ope

#

๐Ÿ˜ฆ

stable shale
#

Oh boyyy

compact wasp
#

damn

slender ravine
#

Same

peak dock
#

same

shut trellisBOT
viscid elbow
#

oh no

shrewd sentinel
#

they rly crashed it

minor cave
#

Poor Eric

native oak
shrewd sentinel
#

aight

#

i in

minor cave
#

In previous years when there's been server-side issues they just don't count LB for that day

humble copper
#

ok so its not just me

vestal kelp
#

It loaded for me, can I paste it for you ?

rancid creek
#

Anyone get in, what's the puzzle text?

humble copper
#

i got my data though

shrewd sentinel
#

alr wtf is this

slender ravine
#

Tbf, maybe just too many people load simultaneously

rancid creek
vestal kelp
shrewd sentinel
#

u can solve it with the example

vestal kelp
native oak
#

guys so uh what do i click on again? i use visual studio code for my code so uh what do I select here ๐Ÿ˜ญ ๐Ÿ™

native oak
#

somebody help meh ๐Ÿ˜ญ

compact wasp
#

this hurts

#

i got scammed out of top 100 because of 500

minor cave
covert arrow
potent pumice
#

5-5-500

covert arrow
#

Alright I'm gonna stop trying and go get lunch

potent pumice
#

at least puzzle directions can be cached on the cdn

gloomy osprey
potent pumice
#

puzzle input generator is erroring out

native oak
humble copper
#

broke again ๐Ÿ˜ญ

tulip elbow
#

i answered part 1 then got error

#

๐Ÿ˜ฆ

potent pumice
#

woah

humble copper
#

i couldnt answer pt 1

#

errored out as soon as i pressed submit

magic oxide
#

wtf is smalltalk

potent pumice
#

today seems to be a continuation of yesterday

native oak
#

guys which

gloomy osprey
#

doesn't really matter, you can just stick with the default

native oak
#

oke

gloomy osprey
#

this might be better in another channel though

potent pumice
native oak
earnest forge
#

177/462 today but there were a load of internal server errors lol

potent pumice
#

im not gonna place today in the slightest

gloomy osprey
potent pumice
#

I don't know rust. the first few days are the best days to get started with a new language

compact wasp
#

ffs i really got 1128/551

potent pumice
#

after that it gets really tough lol

compact wasp
#

because every time i submitted i was 500ing

#

the thing wasn't even loading for me by the time the first answers were in ๐Ÿ˜ญ

slender ravine
#

Done :)

#

...8m ago

#

Well, at least, better than yesterday

zinc kindle
#

Got delayed somewhat by a 500 server error. Still managed top 1000 in part2. Don't think I'll manage that again this year.

late frigate
#

damn people are fast. thought i got it in record time yet still 227/184

earnest forge
compact wasp
gentle cape
#

ill code the solution for today's aoc tmrw bruh

#

im tired

slender ravine
#

I got delayed by ide frozen so 2108/1189 (wasn't delayed that much)

ivory marsh
#

Just finished both parts ๐ŸŽ‰

earnest forge
#

Perhaps this is a silly question but if the leaderboard for today does get cancelled (which it probably will) does the leaderboard aggregator understand that?

reef harness
#

When this event finish ?. I wnat to join but after 8 hours

#

Missed day 1

late frigate
#

iirc the leaderboard was cancelled before

minor cave
earnest forge
limpid grail
#

another easy one

#

but i have classes for another 2 hours ๐Ÿ˜ญ

rancid creek
limpid grail
#

lb rank gone

#

not that it was ever there ๐Ÿ˜›

late frigate
limber aurora
#

it's kind of sad for me that the first time i get global the leaderboard is going to be cancelled. Although i probbaly just would not have gotten it if it was a normal day

rancid creek
late frigate
rancid creek
earnest forge
#

It usually is when an aoc-side issue happens

humble copper
#

this question really messed me up

late frigate
woven oriole
#

the aoc api

#

died

#

and killed my rank

normal dragon
woven oriole
#

๐Ÿ˜”

#

still 859

#

wtf cant rely on library

normal dragon
ivory vigil
#

I doubt it

rancid creek
#

at least we have our private leaderboards.

normal dragon
late frigate
ivory vigil
#

This isn't the first time there's been website issues and clearing the leaderboard just drops ... everything. It's not like he can reset it and start it over.

lone storm
#

Just wondering, how do people on the leaderboard complete it in like 2-5 minutes instantly? Is it just a lot of practice with puzzles like this or do they have other tricks for it

#

Talking about people who actually complete it without AI aid ofcourse

rancid creek
lost musk
#

it took me 40 mins to solve both problems.. i am slow lol

rancid creek
normal dragon
lone storm
#

Thatโ€™s how Iโ€™m thinking about it atleast. Without sitting down for it yet but just reading the question I know itโ€™s gonna take me some time. But I also know how itโ€™ll help me understand/learn more

twin widget
#

guys someone did part 2 fast?

#

it took me like 15 minutes

#

๐Ÿ˜ฆ

#

guuys

#

when you clicked in part 2

#

like barely it started

#

doesnt it took a while?

woven oriole
#

does someone else use aocd lib for submitting

twin widget
#

i do not, i mean, you're just saving like 3 seconds

woven oriole
#

smh

#

it wasted like 20s

#

it died

twin widget
#

JAJAJAJ

twin widget
woven oriole
#

859 p1

#

p2 2k lmao

shrewd sentinel
#

So

#

I discovered pairwise

#

Tmr i will probably do both problems

late frigate
#

i need to study itertools wtf

normal dragon
shrewd sentinel
native oak
#

thanks in advance :#

#

:3

naive wharf
#

Ping where?

somber trench
shrewd sentinel
#

Returns pairs like [(1, 2), (2, 3)] if you give it [1, 2, 3]

somber trench
#

So it pairs adjacent numbers from lists?

shrewd sentinel
#

Yeah

somber trench
#

Interesting

#

Knew this one was gonna whoop my butt

floral hare
#

damn, day 2 part 1 took me longer than I thought

#

(I might have rushed and had to restart everything from start since I messed up the first time)

lone storm
craggy maple
#

I did mine in golang today (errors as return values feels weird)

lone storm
#

Outside of puzzles like this

tender swallow
#

you could just extrapolate the AoC "story" scenario into a plausible real-world usecase

#

but comparing adjacent elements is fairly common. data analysis strikes as one such thing.

shrewd sentinel
#

^

compact wasp
#

numerical analysis

#

for instance approximating derivatives

woven oriole
#

or just cf div3 C

compact wasp
#

div1 or bust

somber trench
#

I've tried about 4 different versions of my program and not one has given me a correct one even though it works with the example data

normal dragon
tender swallow
somber trench
tender swallow
#

yeah. ask your question in there.

#

(specifying that it's for AoC and which day)

hollow wharf
#

offtopic to python: Nothing makes me like Python more than dealing with file input in C++ yikea

cyan sleet
#

I'm an introvert swede, how are you expecting me to smalltalk?

#

also for arch users trying to get the orphaned smalltalk package in the aur going, add this to the end of the prepare function in the PKGBUILD

  sed -i 's/\&inbuf/(void*)\&inbuf/g' packages/iconv/iconv.c
  sed -i 's/const XML_Char \* entityName)/const XML_Char \* entityName, int is_parameter_entity)/g' packages/xml/expat/expat.c
```this made it build for me
#

turns out some api details of libraries might have changed since...2015

magic oxide
#

making smalltalk read files took me a while

#

had conflicting information from different sources

modern terrace
#

i gave up on my smalltalk

cyan sleet
magic oxide
cyan sleet
#

ok, got file read/write working

magic oxide
#

I'm using GNU smalltalk tho so idk if that affects things

cyan sleet
#

I have a ๐Ÿˆ

f := FileStream open: 'input' mode: FileStream read.
f linesDo: [ :line | Transcript show: line; nl ]
magic oxide
#

I tried FileStream read instead of #read and it kept erroring

#

still have no clue why

cyan sleet
#

and yeah, I had to patch GNU smalltalk to even compile on my system ๐Ÿฅด

magic oxide
#

wait does nl on transcript give you newlines

#

all I've seen in the docs is cr

cyan sleet
#

idk

magic oxide
#

yeah I used that too

cyan sleet
#

now, how do I work with strings? ๐Ÿฅด

#

(I guess I could read char by char and write my own integer parsing)

low condor
#

Is gnu small talk what people are using?

magic oxide
#

yeah

cyan sleet
#

we yes

#

people actually doing smalltalk probably use squeak or similar

low condor
#

I see thereโ€™s also something called Squeak

#

Right

magic oxide
#

from what I've read smalltalk is kinda built to be used with a GUI or smthing

#

which is what squeak or pharo is? I think

#

I just homebrewed gnu smalltalk

low condor
#

A GUI? Damn

#

Iโ€™m on GNU/Linux is it just there or needs to be downloaded

modern terrace
cyan sleet
#

splitAt looks promising, but I need to figure out how to use it

glad cairn
#

Advent of Code! editor-bench tool setup

#
  • a daily notifier daemon
tender swallow
glad cairn
#

had a hand on that, but well this is more accurate with LLMs

#

cool thing is that it can easily fetch all years easily
thinking about adding auth + submissions as well, session cookies

glad cairn
slender ravine
#

Then I would never need my browser to do the whole challenge

glad cairn
slender ravine
#

๐Ÿ’€but I don't know java

low condor
#

I have created a Smalltalk program!
It's hello world but I did it

cyan sleet
#

ok, smalltalk done

dim pivot
#

will the lb be cancelled today

#

I really think it should (but I hope not...)

dim pivot
cyan sleet
slender ravine
#

Feel more like fast typing, I know exactly what I want to do but still took like 7mins

#

For first part

cyan sleet
#

it's not much typing

dim pivot
slender ravine
#

No clue how people can do it in 2mins

dim pivot
#

for yesterday's it was ||unpacking 2 lists, sorting them, and then doing some basic operation||

dim pivot
#

I'd definitely say it gets more interesting in the later days though

slender ravine
#

Today is ||sort the list in ASC and desc and compare, then check abs value||

dim pivot
slender ravine
#

Which I know immediately but It took me few mins to type the solution

dim pivot
#

There was a method involving ||polynomial interpolation||, but I used ||math to figure out a formula and had a lot of constant factors||

slender ravine
#

So how someone got it in 2mins ๐Ÿ’€

dim pivot
modern terrace
slender ravine
#

Precisely 66 seconds for first star ๐Ÿ’€

dim pivot
#

Like in pythoon ||there's a trick using zip to generate the pairs automatically||

slender ravine
#

I bet I was restarting my ide at that moment, or reloading to see the question

slender ravine
modern terrace
#

your first mistake was to use an unreliable IDE

dim pivot
#

Idk I always find an ide much easier

#

Otherwise I might forget how to exit vim

#

I also don't like using extensions to get the input or submit

#

Because sometimes these don't work and then I lose my lb place

cyan sleet
#

that was 5 minutes, so a bit slow

slender ravine
cyan sleet
#

I also didn't check that it runs at all ๐Ÿ™ƒ

hollow wharf
#

me when no spoiler

cyan sleet
#

bleh, I thought this was the spoiler channel

slender ravine
cyan sleet
#

apparently I wrote a part 2 bug in those 5 minutes

#

unsure what

modern terrace
cyan sleet
#

in any case, I could probably try to compete to get some points, but god I don't want to wake up at what? 5-6 AM?

modern terrace
#

my school schedule overlaps with aoc :(

strange zinc
#

The heck is smalltalk

#

Anyone got a link?

slender ravine
#

Like this (X

strange zinc
#

Wow.... Thanks m8

slender ravine
#

Tbf I have no idea as well

cyan sleet
cyan sleet
# strange zinc The heck is smalltalk

Smalltalk is a purely object oriented programming language (OOP) that was originally created in the 1970s for educational use, specifically for constructionist learning, but later found use in business. It was created at Xerox PARC by Learning Research Group (LRG) scientists, including Alan Kay, Dan Ingalls, Adele Goldberg, Ted Kaehler, Diana Me...

strange zinc
#

Will have a look later. Where did ppl get it from? Looked at something called squeak

cyan sleet
#

I ended up using gnu smalltalk, which I had to do some patches to to make it compile on my machine ๐Ÿฅด

#

tbh, when you get the initial "oh god what is this" it's not a bad language

#

decently ergonomic

#

just quite different from any C like language

#

fwiw, smalltalk also usually isn't even file based

#

gnu smalltalk allows that

strange zinc
#

fwiw?

cyan sleet
#

for what it's worth

#

I did not want to try to dig into smalltalk images and the vm ๐Ÿฅด

strange zinc
#

Think I'll just stick to python

cyan sleet
#

the fun of the roulette is that you get to experience a lot of different takes on programming

#

some parts you'll like and learn from
some parts you'll hate with a burning passion

strange zinc
#

True. But comfort > trying out stuff

#

I like reading other people's solutions.

glad cairn
#

ig there is an extension already

strange zinc
glad cairn
#

thanky

cyan sleet
dim pivot
#

My first introduction to competitive programming, I'm really happy I did it the first year as this got me into stuff like IOI as well

limber aurora
#

intrestingly it looks like they are yet to remove the points for today from the leaderboard

limpid grail
#

LESSGOO

low condor
#

Iโ€™m giving up on Smalltalk for today

#

The simplest stuff like โ€œhow do I read this file and split this into strings is a headache

#

Iโ€™m sure with enough time Iโ€™ll figure it out but Iโ€™m wanting for time right now ๐Ÿ˜‚

#

You take for granted the ergonomics of other languages until you find yourself without them

mortal bronze
#

This problem was bit tricky ๐Ÿ˜‚

sour tinsel
#

part 2 today was only tricky bc I tried to be clever when the brute force method literally just takes 1ms to process lol

hollow wharf
#

this is the way

limpid grail
#

@weary topaz are you doing AoC?

wary river
sour tinsel
dim pivot
#

I'd say the worst two in the last 2-3 years were these ones

#

I'd say the hardest problem, however, was this

#

Absolutely disgusting problem

pine valley
#

Can anyone point me some AOC tools/framework that boilerplates the read/send of problems? I would like something compatible with Python

low condor
#

I really enjoyed 2022 Day 22

#

For me it was quite satisfying to write a general-ish solution to it

dim pivot
#

I remember the parsing being a nightmare

zenith elbow
#

daily language roulette puns, @low condor? ๐Ÿ‘€

trim pond
#

guys im facing problem in day 2

#

pls help

jovial aspen
#

I saw this in aoc, any idea of what it is?

trim pond
#

nah man

trim pond
celest wharf
#

!code

marsh currentBOT
#
Formatting code on Discord

Here's how to format Python code on Discord:

```py
print('Hello world!')
```

These are backticks, not quotes. Check this out if you can't find the backtick key.

For long code samples, you can use our pastebin.

tender swallow
tender swallow
jovial aspen
low condor
low condor
zenith elbow
mortal bronze
#

Yay

hollow wharf
#

not sure if it was existing last year

woven oriole
#

what happened of the aoc spoiler chat

#

which existed like years ago , 2021-22 iirc

#

it has a lot of my messages with codes i never saved lmao

woven oriole
#

Before threads

#

Iirc there was a channel for 2021

minor turtle
#

what is aoc lube

tender swallow
#

!pypi aoc-lube

marsh currentBOT
tender swallow
#

some helper functions, if you want them

tiny plover
#

Thanks, sorry!

celest wharf
jovial aspen
#

Is that a promo code?
It's like "GET 50%..."

#

Or not

celest wharf
#

GET FIFTY% OFF NEXT PURCHASE fits i think

mossy basin
#

i think there was a thread that mentioned the cipher switched half-way through

celest wharf
#

So this would be different cipher:
XVNVC% KTW GOXA MMQEMOTH

mossy basin
#

or maybe the key is just incomplete, i dunno

#

i guess easy enough to work backwards at this point though

fair spruce
#

Why I got 2 mention ๐Ÿ’€

hollow wharf
#

Forum channels didn't exist back in 2021

#

Hence why 2022 threads

woven oriole
#

Yea

woven oriole
#

!pypi aocd

marsh currentBOT
#

dummy name to pull advent-of-code-data

Released on <t:1607168734:D>.

woven oriole
#

The api died with this today

#

but the api is common obv

#

So wouldn't make difference

dim pivot
#

This failed on me one of the days last year

#

cost me like 30-40 points

#

never again

jovial imp
#

!paster

marsh currentBOT
#
Pasting large amounts of code

If your code is too long to fit in a codeblock in Discord, you can paste your code here:
https://paste.pythondiscord.com/

After pasting your code, save it by clicking the Paste! button in the bottom left, or by pressing CTRL + S. After doing that, you will be navigated to the new paste's page. Copy the URL and post it here so others can see it.

jovial imp
tender swallow
hollow wharf
#

weirdly enough this is a python server ๐Ÿ˜†

faint cove
#

s

thorn inlet
minor ivy
#

Wheres the aoc

#

Day 1

#

Im late by a day I was off from computer

hollow wharf
woven oriole
minor ivy
#

Is it best to have 2 seperate lists to organize them properly?

#

Idk how else I can do it other then having a right and a left list.

leaden tartan
#

Dude Part 2 took me waaaay to long

hollow wharf
hollow wharf
#

you shouldn't post spoilers or how to solve them here

tender swallow
#

don't discuss solutions here.

hollow wharf
#

that's not the channel for such things

minor ivy
weary topaz
cyan sleet
weary topaz
#

what's that?

cyan sleet
weary topaz
#

not yet

#

also tf is vimscript

cyan sleet
#

the vim scripting language

#

surprise

weary topaz
#

yeah, but like... what
(I'll assume it's Turing complete and all)

cyan sleet
#

it's a pretty full featured language

#

it's just a bit odd

rich imp
#

whats yalls fastest solution so far/

hollow wharf
#

Fastest as in?

unique osprey
#

My fastest time was 2021 day 1 where i completed both parts in 00:08:13

#

But if you're looking for runtime, eh i don't care enough to crazy optimize

low condor
#

My fastest time is... checks notes ... 02:36:12. Consequences of having the puzzles start at 5am for me

rich imp
#

no i mean like the fastest to run

#

as in runtime

#

or maybe yall dont do that here idk

unique osprey
#

I'm sure some people do

minor cave
#

runtime isn't really something we check because it really depends on the system you run it in

low condor
#

some of the early problems are so simple that the runtimes there are just not worth measuring

unique osprey
#

that too

low condor
#

My Day 1 is 85micros - at that point I don't really care to check the other solutions to see which is quicker because it's basically instant

rich imp
unique osprey
#

well. This is a python server ๐Ÿ˜„

low condor
#

Makes me feel bad my 85 micros was in Rust as well ๐Ÿ˜‚

#

Thatโ€™s fine though

ripe meteor
#

Any way to see the pool of lang picks for the roulette?

minor cave
#

Later tonight or tomorrow I can provide the total pool I considered, including languages I didn't pick

ripe meteor
#

Cheers, no rush, we'll be here all month

cyan sleet
low condor
#

for one day or the whole month?

cyan sleet
#

sum over all days

low condor
#

i don't think that's happening for me XD

ivory marsh
#

If I want to do that I might need to figure out these fancy O(n) optimizations they are talking about in the rust discord that sound like arcane spells to me

cyan sleet
#

this was my 2022 iirc

signal kestrel
cyan sleet
ivory marsh
#

I forgot about ms

cyan sleet
#

oh god I hope we don't get elisp

weary topaz
ivory marsh
#

Are there any esolangs mixed in?

weary topaz
#

hopefully there's piet

cyan sleet
weary topaz
#

can it even read files?

cyan sleet
#

I hope we don't get overly esoteric stuff ๐Ÿ˜›

#

lolcode could be fun

minor cave
#

I have like 1-2 more not-quite-languages on the list, but nothing eso really. My minimum standard is the language needs to be able to read in input somehow and esolangs don't always hit that mark

slender ravine
#

My solution including automatically submitting the answer so definitely >1ms

ivory marsh
# weary topaz can it even read files?

It can take a char/num of input, I've just assumed for esolangs that the input is put into stdin, since almost all have some sort of "read one thing from stdin" instruction

cyan sleet
#

I also have hopes for postscript

weary topaz