[Tutor] Python

2018-10-12 Thread Tyler Travis via Tutor
I fully understand the concept of what I am trying to do and I know that you can type out the algorithms to find mean, median, and mode but I used a shortcut by import the statistics function. Which yields the same results and the program passes with a 100% in the grading software However, it do

[Tutor] Need help with code

2017-04-19 Thread Tyler Seacrist
Hello, How do I avoid this error message everytime I utilize wordlist = open("words.text") ? >>> wordlist = open("words.txt") Traceback (most recent call last): File "", line 1, in wordlist = open("words.txt") FileNotFoundError: [Errno 2] No such file or directory: 'words.txt' >>> def ca

[Tutor] Need help with code

2017-04-16 Thread Tyler Seacrist
Hello, I need to draw a stack diagram for print_n called with s = 'Hello' and n=2 and am unsure of how to do so. Thanks, Tyler ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: https://mail.python.o

[Tutor] Python 3.5 console logging

2015-11-30 Thread Tyler Smithers
I am doing a project for my school and i am trying to find out how to make a event log. But every where i look all it has is just making a text document and it having in their what they put in their script. But i cant find out how to code python into recording everything that happens when i run the

Re: [Tutor] (no subject)

2014-05-13 Thread student Tyler Northrip
Cant say i was disappointed to see this in my inbox. For help, my suggestion would be to head over to google.com On Mon, May 12, 2014 at 5:10 PM, Chris Acreman wrote: > > > *From:* munazah zaidi > *Sent:* Sunday, May 11, 2014 10:50 AM > *To:* tutor@python.org > *Subject:* [Tutor] (no subject)

[Tutor] Equality Check.

2014-03-02 Thread Tyler Simko
lename.txt,' 'r') file.readlines() variable_name = raw_input() if file[2] == variable_name: #whatever This approach hasn't worked so far, does anyone have any tips? Thanks so much!! -Tyler ___ Tutor maillist - Tutor@python.org To

[Tutor] Fwd: What are these two string-formatting styles called?

2013-06-14 Thread student Tyler Northrip
In response to your points, voice command using visuals, this idea has been explored before. In the book containment by Christian Cantrell they use methods such as this. The main character places a helmet on his head, and writes code using his mind. Voice command was also used as well. Will these

Re: [Tutor] What are these two string-formatting styles called?

2013-06-14 Thread student Tyler Northrip
In response to your points, voice command using visuals, this idea has been explored before. In the book containment by Christian Cantrell they use methods such as this. The main character places a helmet on his head, and writes code using his mind. Voice command was also used as well. Will these

[Tutor] Invisible Characters in Fortran/Python

2011-04-09 Thread Tyler Glembo
ter (\n), but how can I put in other invisible characters? Thank you kindly, Tyler P.S. In VI when I "set invlist" the hidden character ^I shows up in blue at the beginning of the line in place of 4 red spaces that are normally there. I'm assuming it is l

Re: [Tutor] [Cheetahtemplate-discuss] cheetah is extremely hard to debug - error messages are non indicative TypeError: cannot concatenate 'str' and 'int' objects

2009-05-14 Thread R. Tyler Ballance
u were to compile searchesnew.html down to a searchesnew.py and then execute it in a similar fashion, you'd get a "proper" Cheetah backtrace like this: File "base.py", line 413, in respond _v = VFFSL(SL,"page_body",False)() # &#x

[Tutor] How to set up dispatch function

2008-06-20 Thread Tyler Rutschman
a and generate a report. I've only made one type of report thus far but would like to get this part ironed out before adding more. Any suggestions? source code http://codepad.org/VyTAcuji Thanks, Tyler <http://ku.edu> ___ Tutor maillist -

[Tutor] Using Regex from Configuration File

2008-06-20 Thread Tyler Rutschman
;) return opt_name,opt_regex ... rawstr="r"+"\"\"\""+load_config()[1]+"\"\"\"" ... rxinput = re.compile(rawstr) code full code here http://codepad.org/pva1dE1i configuration here http://codepad.org

Re: [Tutor] noob python cgi

2008-03-16 Thread Tyler Smith
On 2008-03-16, Luke Paireepinart <[EMAIL PROTECTED]> wrote: > Tyler Smith wrote: >> Hi, >> [snip explanation] >> Three files follow. First, the html index page, followed by the >> gallery picker, followed by the thumbnail displayer. >> >> Thanks! >

[Tutor] noob python cgi

2008-03-15 Thread Tyler Smith
d a complicated CMS at this point, as I want to learn about the basics of serving up webpages. Three files follow. First, the html index page, followed by the gallery picker, followed by the thumbnail displayer. Thanks! Tyler index: My home page Home Only one thing to do - visit the http://

Re: [Tutor] results not quite 100 percent yet

2008-02-21 Thread Tyler Smith
ed, and it takes advantage of Python's listy goodness. My 2 cents! Tyler import random entrance = 6 exit = 11 death_room = 13 table= [[ 0, 2, 0, 0, 0, 0, 0], [ 1, 3, 3, 0, 0, 0, 0], [ 2, 0, 5, 2, 0, 0, 0], [ 0, 5, 0, 0, 0, 0, 0], [ 4, 0, 0, 3,15,13, 0

Re: [Tutor] results not quite 100 percent yet

2008-02-21 Thread Tyler Smith
ers in your code with the variables means you only have to make one change that propagates through the entire program if you change the map layout. It also means that if you're reading your code in a year you won't have to remember that 

Re: [Tutor] newbie code review please!

2008-02-04 Thread tyler
On Mon, Feb 04, 2008 at 03:27:35PM -0400, tyler wrote: > On Mon, Feb 04, 2008 at 11:56:17AM -0500, Kent Johnson wrote: > > Tyler Smith wrote: > > > >> That cleaned up a lot. However, I couldn't figure out a way to do > >> random.choice(word_hash[(w1

Re: [Tutor] good reference book recommendations

2008-02-04 Thread tyler
Beazely's Essential Reference and the Martelli's Nutshell book are both aimed to fill this role - any reason to choose one over the other? The free library reference would almost do for me, except that I want a hardcopy and it's a big document to print out. Thanks! Tyler -- I ne

Re: [Tutor] newbie code review please!

2008-02-04 Thread Tyler Smith
hen I need to add a few lines to put the value back into the set afterwards. Is there a way to randomly lookup a value in a set without removing it from the set? I had better success with collections.defaultdict(list), as pasted below. Cheers, Tyler #! /usr/bin/python2.5 import sys, r

Re: [Tutor] newbie code review please!

2008-02-04 Thread tyler
hen I need to add a few lines to put the value back into the set afterwards. Is there a way to randomly lookup a value in a set without removing it from the set? I had better success with collections.defaultdict(list), as pasted below. Cheers, Tyler #! /usr/bin/python2.5 import sys, r

[Tutor] newbie code review please!

2008-02-03 Thread Tyler Smith
nd occasionally amusing bit of text based on the input. Any comments welcome! Thanks, Tyler #! /usr/bin/python import sys, random word_max = 1000 # Read in file infile = open(sys.argv[1], 'r') ifstring = infile.read() # break file into words iflist = ifstring.replace('\n', &#