Re: [Tutor] Semantic Error: Trying to access elements of list and append to empty list with for loop

2016-06-02 Thread Olaoluwa Thomas
WordExtract.py since it does just that. :) *Warm regards,* *Olaoluwa O. Thomas,* *+2347068392705* On Thu, Jun 2, 2016 at 6:44 PM, Steven D'Aprano <st...@pearwood.info> wrote: > On Thu, Jun 02, 2016 at 06:05:43PM +0100, Olaoluwa Thomas wrote: > > > fname = raw_input('Enter file

[Tutor] Semantic Error: Trying to access elements of list and append to empty list with for loop

2016-06-02 Thread Olaoluwa Thomas
Hi Tutor, I'm trying to parse words in a file line by line and place all words into another list but I keep getting a list with nested lists. I would normally pore over it and go to google and fix my problems but this one escapes me and frankly, I'm tired of being stuck in the same place for

Re: [Tutor] Issues converting a script to a functioin (or something) [SOLVED]

2016-05-01 Thread Olaoluwa Thomas
Gotcha. *Warm regards,* *Olaoluwa O. Thomas,* *+2347068392705* On Sun, May 1, 2016 at 7:14 PM, Alan Gauld via Tutor <tutor@python.org> wrote: > On 01/05/16 14:38, Olaoluwa Thomas wrote: > > > Thanks for your feedback. Please do not hesitate to provide more as I > shall >

Re: [Tutor] Issues converting a script to a functioin (or something) [SOLVED]

2016-05-01 Thread Olaoluwa Thomas
enath...@gmail.com> wrote: > On Sun, May 01, 2016 at 5:34 PM, Olaoluwa Thomas <thomasolaol...@gmail.com> > wrote: > > The novice Python programmer is back. > > I'm trying to incorporate a function and its call in the GrossPay.py > script > that Alan solved for me

[Tutor] Issues converting a script to a functioin (or something)

2016-05-01 Thread Olaoluwa Thomas
The novice Python programmer is back. I'm trying to incorporate a function and its call in the GrossPay.py script that Alan solved for me. It computes total pay based on two inputs, no. of hours and hourly rate. There's a computation for overtime payments in the if statement. Something seems to

Re: [Tutor] Issue with Code [SOLVED]

2016-04-30 Thread Olaoluwa Thomas
Thank you so much, Alan. That fixed it (See Script 2[SOLVED] below). For the purpose of record-keeping, I'm pasting the entire code of all scripts below as I should have done from the very beginning. P.S. How were you able to open attachments with the restrictions on this mailing list? Script 1

[Tutor] Fwd: Issue with Code

2016-04-30 Thread Olaoluwa Thomas
Hi All, I sent this forwarded email earlier but hadn't subscribed to the mailing list so I guess that's why I didn't get a response. Please review and advise. *Warm regards,* *Olaoluwa O. Thomas,* *+2347068392705* -- Forwarded message -- From: Olaoluwa Thomas <thomasol

[Tutor] Issue with Code

2016-04-30 Thread Olaoluwa Thomas
Hi, I'm new to Python and programming in general. I came across a simple exercise that is used to compute gross pay when prompted to enter number of hours and hourly rate. I've attached the scripts in question (created via Notepad++). The 1st script I wrote worked perfectly. The 2nd script makes