Python Forum
simulate static local varibles with getattr - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: General (https://python-forum.io/forum-1.html)
+--- Forum: Tutorials (https://python-forum.io/forum-4.html)
+--- Thread: simulate static local varibles with getattr (/thread-8386.html)



simulate static local varibles with getattr - gjenkinslb - Feb-17-2018

Just post YouTube video with how to use getattr builtin method to create function state that presist between calls. This is done more to teach newer python users and is not necessarily how you would solve this problem in general. see: https://youtu.be/yHMqif_FzHY


RE: simulate static local varibles with getattr - Larz60+ - Feb-18-2018

This is not youtube!
it is youtu.be, but is guess that still works


RE: simulate static local varibles with getattr - buran - Feb-19-2018

(Feb-18-2018, 01:43 AM)Larz60+ Wrote: This is not youtube!
it is youtu.be, but is guess that still works
It's the standard short link created when you click on Share button


RE: simulate static local varibles with getattr - Larz60+ - Feb-19-2018

Quote:It's the standard short link created when you click on Share button
Realized that after original post, that's why the addition of:
Quote:it is youtu.be, but is guess that still works