ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> python-tutor
python-tutor
Re: [Tutor] FW: Frustrated Beginner
by Daniel Watkins other posts by this author
Sep 29 2005 9:53AM messages near this date
Re: [Tutor] Book recommendations? | [Tutor] Python equiv to PHP "include" ?
Rosalee Dubberly wrote:
>  ## Now I am trying to modify the function to replace eggs with toast
>  and spam with jelly. I have spent days and nothing works. Can you send
>  me in the right direction?? 

The obvious answer (that has already been mentioned) is to simply
replace the words in the actual program with their substitutes. However,
this is so obvious I sincerely hope that you don't mean this by the
question.

The right direction, as I understand it, would be to set the text to be
printed in a variable, which can then be passed to the function. This
will allow you to change the text to whatever you want easily, as well
as including the possibility for user input later.

An example is attached, so you can try to work it out yourself without
seeing it.

Dan
Attachments:
firstpart.py
unknown1
unknown2


Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved