El viernes, 28 de marzo de 2014 11:45:51 UTC-6, Stefan Karpinski escribió: > > That seems like a reasonable way to do it. >
OK, thanks. > > > On Fri, Mar 28, 2014 at 1:36 PM, David P. Sanders > <[email protected]<javascript:> > > wrote: > >> Hi, >> >> I often need to share state (a collection of modificable variables) >> between functions. >> In Python and C++, I would do this by putting everything inside a class, >> and the class variables (attributes) >> would act as "pseudo-global" variables (an excellent description that a >> student in one of my courses once came up with!) >> >> What is the julian way of doing this? Put the state variables inside a >> new type and make all functions modify the variables inside that state >> object? >> >> Thanks, >> David. >> > >
