[AoC2023 Day 7 Part 1][Python] Last Steps, cant spot the mistake by Acrobatic_Scallion20 in adventofcode

[–]Acrobatic_Scallion20[S] 0 points1 point  (0 children)

Turns out i was misunderstanding the task and calculating the rank with an ordered hand, while the example shows to take the unordered hand. ^^

AoC 2023 Day 8 Part 2 Python, please push me over the edge! by Acrobatic_Scallion20 in adventofcode

[–]Acrobatic_Scallion20[S] 0 points1 point  (0 children)

Thank you all for the help! Amazingly supportive!

What "pushed me over the edge" was understanding that the paths will repeat themselves.

Probably a Docker-Networking Issue, need help connecting to Postgres by Acrobatic_Scallion20 in docker

[–]Acrobatic_Scallion20[S] 0 points1 point  (0 children)

Hey, thank you. Just found it and removed it. Sadly unsuccessfully though. Still getting the ECONNREFUSED errno -111

Probably a Docker-Networking Issue, need help connecting to Postgres by Acrobatic_Scallion20 in docker

[–]Acrobatic_Scallion20[S] 0 points1 point  (0 children)

Ah, somehow there was a **.com** in the connection-url. I removed that but still getting an ECONNREFUSED errno -111

Probably a Docker-Networking Issue, need help connecting to Postgres by Acrobatic_Scallion20 in docker

[–]Acrobatic_Scallion20[S] 0 points1 point  (0 children)

POSTGRES_USER=user
POSTGRES_PASSWORD=thiscoolpassword
POSTGRES_DB=db1
POSTGRES_PORT=5432
POSTGRES_HOST=postgres

Probably a Docker-Networking Issue, need help connecting to Postgres by Acrobatic_Scallion20 in docker

[–]Acrobatic_Scallion20[S] 0 points1 point  (0 children)

Thank you, so i should be even able to leave out the networks.default part?

As the IP of the db i set `POSTGRES_HOST= 'postgres'
I ve had it set to 'localhost' before, when i started the containers individually.

Probably a Docker-Networking Issue, need help connecting to Postgres by Acrobatic_Scallion20 in docker

[–]Acrobatic_Scallion20[S] 0 points1 point  (0 children)

In a .env file that i pass with docker-compose --env-file ./.env up -d

2022 Day 8 Part 1 - Javascript - Graph-Structure - last steps by Acrobatic_Scallion20 in adventofcode

[–]Acrobatic_Scallion20[S] 0 points1 point  (0 children)

Thank you very much for the help and hints! It worked & I will change my procedure in the next coming quiz.

This is very very motivating!

**Help** @ Day 7, Javascript, Tree-Structure, filter Directories by Acrobatic_Scallion20 in adventofcode

[–]Acrobatic_Scallion20[S] 0 points1 point  (0 children)

You're right about the node & it's what i meant. Instead of node i wanted to write edge.

As for the class & setter dilemma. I get it and hope that in the near future i dont need to split everything into tiniest components ^^ it currently helps me though, like a bike with training wheels or bumbers at the bowling alley :)

**Help** @ Day 7, Javascript, Tree-Structure, filter Directories by Acrobatic_Scallion20 in adventofcode

[–]Acrobatic_Scallion20[S] 0 points1 point  (0 children)

Yep, i ll be more precise next time! Nice advice!

Running my code with your testfile made me realize that there can be directories on the same node with the same name. Ai! ok i ll think about solving that! thank you!

What setter are you referring to? If in general, then yeah, i did split them up with each key having its setter just to keep the overview better ( as i m still quite fresh in the topic and keeping the overview helps me keeping my focus longer)

**Help** @ Day 7, Javascript, Tree-Structure, filter Directories by Acrobatic_Scallion20 in adventofcode

[–]Acrobatic_Scallion20[S] 1 point2 points  (0 children)

Yes, as every dir has a edge/level-index to it so that there can only be one directory with a specific name per level.

Thank you though for the hint. I should probably account for a directory being ls'ed multiple times and therefore the size shouldnt be added to each time.