[Tutor] powerball

2008-06-12 Thread max baseman
hello and thank you everyone for your help. I apologize for my ignorance when it came to knowledge of what the powerball is it is not as wide spread as i had thought it was the powerball is a form of lottery their are 5 numbers between 1 and 55, and then their is the powerball between 1 and

[Tutor] powerball

2008-06-11 Thread max baseman
as a fun little project i scripted a powerball program. it seems to have a bug in it that i cant find. from random import randrange wins=0 win=[] count =0 while count !=5: number=randrange(55)+1 win.append(number) count=count+1 powerball=randrange(42)+1 count=0 win.sort() while coun

[Tutor] locating python scripts

2008-01-06 Thread max baseman
hey i just have a small question, doesn't have much to do with programing but it has to do with python. anyways Im running a apple computer version 10.4 and have been keeping my scripts in the user folder i was wondering where and how i can change the files that python looks in when looking

[Tutor] war cards

2007-12-24 Thread max baseman
hello all, i have been rolling the idea of writing a simple script to play the classic card game war. i thought it would be good for me because their is no skill in the game. while thinking of how to write it i got stuck on one bit, how do i make it so that their is one of each card and i c

[Tutor] another quickie

2007-10-04 Thread max baseman
hello all, im sorry but i might be asking a lot of Tkinter questions for a bit. im still working on my first GUI, it is very simple all i want it to do is open a text file, write to it, than save it. so far i have a GUI with the ability to right text (nothing amazing), but i don't know how

Re: [Tutor] Tkinter text

2007-10-03 Thread max baseman
27;ve ever read i really like and that was the first place i checked but in the GUI section the text entry bit is for a single line of text On Oct 3, 2007, at 3:58 PM, Alan Gauld wrote: > > "max baseman" <[EMAIL PROTECTED]> wrote > >> i've got two qu

[Tutor] Tkinter text

2007-10-03 Thread max baseman
hello im working on my first simple gui using Tkinter i've got two questions, 1st how would you go about creating a hidden text file that trys on a apple and if that does not work tries to do it on a windows computer? the program I'm making is a vary simple text editor for one file all it ne

[Tutor] quick question

2007-09-24 Thread max baseman
hello just a quickie today :) how is python with patters or finding a rule for something ie: in out tables for example how hard would it be to write a program that take's a input of a in out table and finds the rule ex: in out 10 23 5 13 1

Re: [Tutor] making math problems mmmm fun

2007-09-11 Thread max baseman
sentences run together and > difficult to read. :-) Honestly, I just gave up after the first two > lines. > > max baseman wrote: >> haha :) yeah it's the new imp stuff i like parts of the idea but >> other parts i really dislike basically it TRIES to make math &

Re: [Tutor] making math problems mmmm fun

2007-09-10 Thread max baseman
wow this is a bit over my range of knowledge im impressed :) ill be happy to look at it but i think i will see if i can end up writing my own :) worse case ill do it by hand will not take long hmm wow thanks :) On Sep 10, 2007, at 8:47 PM, John Fouhy wrote: ### import operator bino

Re: [Tutor] making math problems mmmm fun

2007-09-10 Thread max baseman
problem was listed in a chapter entitled > "Cruel and Unusual"! > > -Sam > ________ > - Original Message > From: max baseman <[EMAIL PROTECTED]> > To: tutor@python.org > Sent: Monday, September 10, 2007 6:28:23 PM > Sub

[Tutor] making math problems mmmm fun

2007-09-10 Thread max baseman
hello all this is a homework in math i dont need to program it but i would like to :) so like any other time pleas dont just give a answer tutorials or a explanation. i dont like to use script something i dont understand :) thanks basically the problem is to find a bunch of ways to put 1,

[Tutor] making math problems mmmm fun

2007-09-10 Thread max baseman
hello all this is a homework in math i dont need to program it but i would like to :) so like any other time pleas dont just give a answer tutorials or a explanation. i dont like to use script something i dont understand :) thanks basically the problem is to find a bunch of ways to put 1,

Re: [Tutor] checking if a number is evan or odd

2007-09-04 Thread max baseman
r. > But look at the mod operator '%' - It returns the remainder > of an integer division. An even number is exactly divisible > by 2. > > HTH, > > Alan G. > > "max baseman" <[EMAIL PROTECTED]> wrote > >> about before ive let it sit for

Re: [Tutor] checking if a number is evan or odd

2007-09-03 Thread max baseman
h > > if number%2 == 0: >number = number/2 > > Why do you need to convert it to a float? > > Off topic: > Is this a PE problem? I remember doing the same thing. > > max baseman wrote: >> hello just a quick check in, it's about the same program i was >

[Tutor] checking if a number is evan or odd

2007-09-03 Thread max baseman
hello just a quick check in, it's about the same program i was asking about before ive let it sit for a few days now and i reached a number to high to convert to a decimal by adding 0.0 here's the program: count=1 numstart=268549802 number=0 high=0 a=0 while 1==1: numstart=numstart+1

Re: [Tutor] clearing a text document

2007-08-30 Thread max baseman
Johnson wrote: > max baseman wrote: >> right it's for a quick math "game" the rules are simple you start >> with any number to get the next number you, a. if it's odd >> multiply by 3 than add 1 or b. if it's even divide by two, the >>

Re: [Tutor] clearing a text document

2007-08-30 Thread max baseman
cool thank you :) On Aug 29, 2007, at 11:02 PM, Luke Paireepinart wrote: > max baseman wrote: >> right it's for a quick math "game" the rules are simple you start >> with any number to get the next number you, a. if it's odd >> multiply by 3 th

Re: [Tutor] clearing a text document

2007-08-29 Thread max baseman
t 4,2,1,4,2,1... now im looking for a a number with a very high amount of numbers till you get to 1 so every time it's finds a new one i would like it to write that to a file and clear the last entry, On Aug 29, 2007, at 5:45 PM, Alan Gauld wrote: > > "max baseman" <

[Tutor] clearing a text document

2007-08-29 Thread max baseman
quick question how would i clear a text document? ___ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor

Re: [Tutor] the and command

2007-08-24 Thread max baseman
if a+1 in l7: print a+1 On Aug 24, 2007, at 1:25 AM, Alan Gauld wrote: > > "max baseman" <[EMAIL PROTECTED]> wrote >> im checking if a number is in all 5 of the other lists and when >> i use the and command it seems to just be checking if it's in a >>

[Tutor] the and command

2007-08-23 Thread max baseman
hello im checking if a number is in all 5 of the other lists and when i use the and command it seems to just be checking if it's in a least one of the others, here is the program it's choppy i needed it for a quick calculation so it's not pretty but it's not long: n2=2 n3=3 n4=4 n5=5 n6=6 n

[Tutor] web browser

2007-07-21 Thread max baseman
has anyone ever written a web browser with python and Tkinter? if so is there any documentation on it? if not does anyone know if their which tutorials i should read if i wanted to write one for my apple? i don't know vary much Tkinter so i was going to start there then i thought i would be us

[Tutor] curses

2007-07-16 Thread max baseman
hello all sorry to bother I'm working on my first curses program ive been wanting to learn curses for a while now and now that a have a lop top with fedora core running in run level 3 ware im trying to program all the tools i'll use but curses will be my only gui ALAN has been helping me wi

[Tutor] reading random line from a file

2007-07-14 Thread max baseman
im writing a quick quote reader that spits out a random quote from a show but cant get it to pick randomly i tried a=randrange(820)+1 text.readline(a) and i would prefer not having to bring evryline into the program then picking like for line in text.readlines(): lines.append(text) .

[Tutor] curses

2007-07-14 Thread max baseman
hello all sorry to bother I'm working on my first curses program ive been wanting to learn curses for a while now and now that a have a lop top with fedora core running in run level 3 ware im trying to program all the tools i'll use but curses will be my only gui ALAN has been helping me wi

[Tutor] curses

2007-07-12 Thread max baseman
ok after reading a few tutorials i think i know enough to write my program here it is not commented yet though sorry: import curses from time import sleep scr=vurses.initscr() population=0 seconds=0 try: scr.nodelay(1) scr.leaveok(0) max_y, max_x = scr.getmaxyx()