Re: [Tutor] would someone please explain this concept to me

2019-06-04 Thread Steven D'Aprano
In case you are still confused, we can simplify the whole process by eliminating the unnecessary use of an external module. blank = {} feeds = {} feeds['a'] = blank feeds['a'][1] = "Hello" print(blank) # will print {1: 'Hello'} We can see that the dict named "blank" and the dict named

Re: [Tutor] would someone please explain this concept to me

2019-06-04 Thread Steven D'Aprano
On Tue, Jun 04, 2019 at 11:37:23PM +, nathan tech wrote: > globals.py: > > feeds={} > blank_feed={} > blank_feed["checked"]=1 > blank_feed["feed"]=0 That is more easily, and better, written as: feeds = {} blank_feed = {"checked": 1, "feed": 0} > main file: > > import globals as g > #

Re: [Tutor] would someone please explain this concept to me

2019-06-04 Thread Alan Gauld via Tutor
On 05/06/2019 00:37, nathan tech wrote: > Hi there, > > So I have just fixed a huge bug in my program, but don't understand > exactly... How it bugged. Neither do I, your explanation raises more questions than answers. > globals.py: > feeds={} > blank_feed={} > blank_feed["checked"]=1 >

[Tutor] would someone please explain this concept to me

2019-06-04 Thread nathan tech
Hi there, So I have just fixed a huge bug in my program, but don't understand exactly... How it bugged. Confused? I sure was. Here's some code: globals.py: feeds={} blank_feed={} blank_feed["checked"]=1 blank_feed["feed"]=0 main file: import globals as g # some code that loads a feed

Re: [Tutor] Fw: Download issues for Python

2019-06-04 Thread Grant Edwards
On 2019-06-04, tom milikic wrote: > [...] > > It states that this is missing from my computer -: > > api-ms-win-crt-runtime-l1-1-0.dl [You left off the second 'l'. Precision is very important when dealing with software problems.] You can often the answer just by Googling the error message:

[Tutor] Fw: Download issues for Python

2019-06-04 Thread tom milikic
Hi my name is Tom and I come from Brisbane in Australia. I cannot seem to download Python on my computer as I really need it to help with my Quantitative Finance studies. It seems to say that some program is missing from my computer? What do I do? I am running Windows and a Toshiba

Re: [Tutor] Interactive editing of variables.

2019-06-04 Thread Mats Wichmann
On 6/4/19 2:49 AM, Steven D'Aprano wrote: > The bad news is that this only works on Linux and other Unix systems > with readline installed (which nearly all of them do). It won't work > under Windows. > > But if you install the third-party library pyreadline, you *may* be able > to use that

Re: [Tutor] Interactive editing of variables.

2019-06-04 Thread Steven D'Aprano
Hi Sean, On Sat, Jun 01, 2019 at 12:53:00PM +1000, mhysnm1...@gmail.com wrote: > I have had a look and cannot find an example where I can interactively edit > a content of a variable at the command line. I do not want to use GUI at > all. As this is a simple program only requiring CLI. I have no