[Tutor] Interactive editing of variables.

mhysnm1964 at gmail.com mhysnm1964 at gmail.com
Fri May 31 22:53:00 EDT 2019


Hello all,

 

Python 3.7, windows 10.

 

I have no clue on how to achieve what I want to do and the code I have
creates an hash. As shown below:

 

for row in description:

    text = description_rejex(row) # applies a regular expression test
function to remove text. Returns a list.

    if text[0] not in narration: # Checks a hash to see if the first element
is in the dictionary.

        Result = input(text[0]) # the issue, I want to modify some of the
results manually before going into the dictionary.

        narration[result] = text

 

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 problems
showing the prompt, but cannot insert text into the edit (input) area. Any
ideas?

 



More information about the Tutor mailing list