Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Chaining scripts
#4
(Jan-16-2018, 09:25 AM)Steffenwolt Wrote: The foo, bar and cux are fake names to be replaced by reall ones
Yes, they are example names, or more technically metasytactic variables. Python also uses ham, eggs, spam for these.

The common module may contain as many variables as needed.

Don't hesitate to use classes. A class instance such as state in my example is nothing but a place where you can store data by using the dot syntax, such as
state.bar = 'hello'
state.mylist = ['a', 'b', 'c']
print(state.bar, state.mylist)
etc.
Reply


Messages In This Thread
Chaining scripts - by Steffenwolt - Jan-15-2018, 09:30 PM
RE: Chaining scripts - by Gribouillis - Jan-15-2018, 10:23 PM
RE: Chaining scripts - by Steffenwolt - Jan-16-2018, 09:25 AM
RE: Chaining scripts - by Gribouillis - Jan-16-2018, 09:34 AM

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020