I'm Nat. I turn confusing coding docs into plain English for beginners.
if git, python, sql or AI tools make you feel lost, stick around:
- one simple tip a day
- quick quizzes
- memes about the pain
cheat sheets: https://t.co/yelxnEcHQI
It prints [1, 2, 3, 4]. a and b point to the same list, not a copy. If this kind of thing trips you up, the free cheat sheet is here: https://t.co/yelxnEca1a
CAN YOU SOLVE THIS? NO PEEKING.
a = [1, 2, 3]
b = a
b.append(4)
print(a)
What does it print? Make your guess first, then look down in the replies for the answer.
This one trips a lot of beginners, and it's not because the code is long. In everyday language, "b = a" sounds like "make b a copy of a." In Python, for a list, that line does not make a new list. It gives the same list a second name.
That's why a change made through one name can show up through the other. People miss it when they're moving fast, because the line looks so simple.
If you actually wanted a separate list, copy it:
b = list(a)
or:
b = a.copy()
Then changes to b stay on b.
This week, any time you point a new name at a list, pause and ask: do I want a second name, or a copy? If you want a copy, use one of those two lines.
Don't scroll to the answer until you've guessed. Check the replies after, and see if you were right.
I made a short cheat sheet on this. Try the free one first, it's down below.
@theo translation: same task, same plan, it shouldn't eat your limit any faster. if it does, report it. finally a bug report people will be happy to write
404 vs 500 — whose fault is it?
4xx means the request. 5xx means the server.
And 401 and 403 are not the same thing.
Save this for the next confusing error.
@buildwithpb coding isn't dead for juniors, it moved to review. prompting writes the code. knowing a little code is how you notice it's wrong before your users do
Quick Git check.
You edit https://t.co/uiCcy3GIdJ, git add it, edit it again, then commit.
Does that second edit get committed?
A) Yes
B) No — add again first
C) Only if you force
Guess first. Then watch.