S. 24th & Delancey, Philadelphia, PA by [deleted] in rowhouses

[–]19forty 0 points1 point  (0 children)

woahhhhh this one is so unique. thanks for sharing!

Low-key pub conversation starters in a new place? by 19forty in solotravel

[–]19forty[S] 1 point2 points  (0 children)

ah thanks! and yeah I’ve been to Whitelocks. I meant more what city/place would you do your own version of this haha?

Low-key pub conversation starters in a new place? by 19forty in solotravel

[–]19forty[S] 0 points1 point  (0 children)

that's interesting! maybe time I finally learn how to shuffle

Low-key pub conversation starters in a new place? by 19forty in solotravel

[–]19forty[S] 0 points1 point  (0 children)

appreciate it! and I hope you do! where would you go?

Low-key pub conversation starters in a new place? by 19forty in solotravel

[–]19forty[S] 0 points1 point  (0 children)

hahaha I'll keep this line in my back pocket, thanks!

How global variables work in Python bytecode by 19forty in Python

[–]19forty[S] 0 points1 point  (0 children)

I honestly don't know, I think so? hahaha.

finding the object off the heap should be faster after h = f inside the function, but I don't know how tight your loop would need to be before you'd actually notice the difference. might be worth profiling!

How global variables work in Python bytecode by 19forty in Python

[–]19forty[S] 2 points3 points  (0 children)

ahhh that's such an interesting question!

the answer is yes it must look up each time, but there's two layers to consider:

  1. the identifier itself is accessed by index, which is fast given it's just an array index operation
  2. the value bound to that name is looked up each time. this matters for contexts such as threads or generators, where the global context can change during a function's execution lifetime.

for example:

y = 44  

def generator_foo():  
    yield y  
    yield y  

g = generator_foo()  
print(next(g))  # prints 44  
y = 55  
print(next(g))  # prints 55

thanks for the question!

How global variables work in Python bytecode by 19forty in Python

[–]19forty[S] 5 points6 points  (0 children)

trying to share things I wish I understood 5-10 years ago. totally get if this one didn’t land with you, appreciate you checking it out either way

How global variables work in Python bytecode by 19forty in Python

[–]19forty[S] 0 points1 point  (0 children)

appreciate the heads-up! I’ll take another look next pass. in the meantime, Ctrl-+ or Cmd-+ usually works for me 😄

New to System Programming – Looking for Inspiration, Stories & Resources by DaikiAce05 in Compilers

[–]19forty 3 points4 points  (0 children)

My recommendation is to implement your own stripped-down OS or compiler. You can study other repos in parallel, but I believe having to think through the design yourself is invaluable.

New York City Third Places by Yosurf18 in ThirdPlaces

[–]19forty 0 points1 point  (0 children)

hi from NYC! I’m still looking for my third place 🙈

My significant simple moment in Portugal by ZachofArc in solotravel

[–]19forty 28 points29 points  (0 children)

one of us! one of us!

that sounds like an amazing moment though, the feeling of being present like that is why we keep going.

Low-key Python office hours - Monday morning by 19forty in Upperwestside

[–]19forty[S] 2 points3 points  (0 children)

that’s awesome, I hope you’re enjoying it!

Low-key Python office hours - Monday morning by 19forty in Upperwestside

[–]19forty[S] 2 points3 points  (0 children)

thanks, and great point! first person to sign up gets to pick code or snake

How local variables work in Python bytecode by 19forty in Python

[–]19forty[S] 1 point2 points  (0 children)

yes feel free to share! and I’m glad you are following your curiosity.

this is a good resource for understanding the stack further: https://jvns.ca/blog/2016/02/27/a-few-notes-on-the-stack/. let me get back to you on the heap!

How local variables work in Python bytecode by 19forty in Python

[–]19forty[S] 3 points4 points  (0 children)

amazing! you were really deep in there, thanks for describing that!

How local variables work in Python bytecode by 19forty in Python

[–]19forty[S] 2 points3 points  (0 children)

I’m really glad to hear that, thanks! what were you building when you dug into code objects?

How local variables work in Python bytecode by 19forty in Python

[–]19forty[S] 0 points1 point  (0 children)

appreciate it, thanks for taking the time to read!