Re: Why does my compiler say invalid syntax then highlight...?

2008-03-11 Thread Nathan Pinno
On Mar 11, 1:12 pm, Mensanator <[EMAIL PROTECTED]> wrote: > On Mar 11, 3:36 am, Duncan Booth <[EMAIL PROTECTED]> wrote: > > > Mensanator <[EMAIL PROTECTED]> wrote: > > > On Mar 10, 10:44‹¨«pm, Nathan Pinno <[EMAIL PROTECTED]> wrote: > > >> W

Why does my compiler say invalid syntax then highlight...?

2008-03-10 Thread Nathan Pinno
x = x + 1 print primes elif run == 2: break else: print "Sorry, not a choice. Please enter your choice again." print "Goodbye." How do I fix such an invalid syntax? TIA, Nathan Pinno -- http://mail.python.org/mailman/listinfo/python-list

Re: How to factor using Python?

2008-03-10 Thread Nathan Pinno
On Mar 10, 12:10 pm, Mensanator <[EMAIL PROTECTED]> wrote: > On Mar 10, 12:48 am, Gabriel Genellina <[EMAIL PROTECTED]> wrote: > > > On 10 mar, 02:08, Nathan Pinno <[EMAIL PROTECTED]> wrote: > > > > How do I factor a number? > > If factoring is ac

How to factor using Python?

2008-03-09 Thread Nathan Pinno
How do I factor a number? I mean how do I translate x! into proper Python code, so that it will always do the correct math? Thanks in advance, Nathan P. -- http://mail.python.org/mailman/listinfo/python-list

Is it possible to return a variable and use it...?

2008-03-02 Thread Nathan Pinno
Hello all, Is it possible to return a variable and then use it like the following: [code] dir exp_1: while hen != "*" sum = sum + hen return sum dir exp_2: if sum >= total_needed: print "Profit can be made." else: print "Expect a loss." total_needed = int(raw_input

Is there a way to create a button in either pygame or livewires?

2005-11-18 Thread Nathan Pinno
Hey all, Is there a way to create a button in either pygame or livewires, that is able to be clicked and when clicked sends a command to restart the program? Thanks, Nathan Pinno -- For great sites go to: http://www.the-web-surfers-store.com MSN Messenger: [EMAIL PROTECTED],com Yahoo

Re: Can anyone tell me if pygame and Tkinter can work together?

2005-11-18 Thread Nathan Pinno
t; <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Nathan Pinno wrote: > >> It's a warning that says: >> >> Can only use * in top level or something like that. >> >> It's kind of annoying > > why? importing tons of unknown stuff i

Re: Can anyone tell me if pygame and Tkinter can work together?

2005-11-16 Thread Nathan Pinno
It's a warning that says: Can only use * in top level or something like that. It's kind of annoying, but the program still ran after I made the import * lines top level, and removed the def's. Nathan Pinno. -- For great sites go to: http://www.the-web-surfers-store.com MSN Me

Re: Can anyone tell me if pygame and Tkinter can work together?

2005-11-15 Thread Nathan Pinno
5 AIM: f3mighty "Nathan Pinno" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Sounds good, I'll give it a try and see what happens, and report back > about > my results. > > > Nathan Pinno, > Owner/operator of The Web Surfer's Store. >

RE: Can anyone tell me if pygame and Tkinter can work together?

2005-11-15 Thread Nathan Pinno
Sounds good, I'll give it a try and see what happens, and report back about my results. Nathan Pinno, Owner/operator of The Web Surfer's Store. http://www.the-web-surfers-store.com/ MSN Messenger: [EMAIL PROTECTED] Yahoo! Messenger: spam_swatter31 AIM: f3mighty ICQ: 199020705 ---

RE: Can anyone tell me if pygame and Tkinter can work together?

2005-11-15 Thread Nathan Pinno
Thanks. I was going to use TKInter to pop up a message box, then use pygame to run the game and display the score on the playing surface. Is this still possible (I'm using Python 2.4.1 and Pygame 1.7.0 on WinXP with Service Pack 2)? Nathan Pinno Nathan Pinno, Owner/operator of The Web Sur

Can anyone tell me if pygame and Tkinter can work together?

2005-11-15 Thread Nathan Pinno
Hi, Can anyone tell me if pygame and Tkinter can work together in the same application? I thought I'd better ask before trying it, since both use widgets. Thanks, Nathan Pinno -- For great sites go to: http://www.the-web-surfers-store.com MSN Messenger: [EMAIL PROTECTED],com Yahoo! Mess

Re: (OT) Is there something that people can use instead of full blown Python to run Python programs?

2005-08-18 Thread Nathan Pinno
I was thinking something like Java's Runtime Environment, but that might also do.   Thanks, Nathan Pinno ---Early to bed,Early to rise,Makes a man healthy, wealthy, and wise.--Benjamin Fra

(OT) Is there something that people can use instead of full blown Python to run Python programs?

2005-08-18 Thread Nathan Pinno
Hi all,   Is there something besides the full blown version of Python that people can use to run Python programs, or do they have to use the full blown version of it?   Thanks, Nathan ---Early to bed,Early to rise,Makes a man healthy

Re: Who uses input()? [was Re: question on "input"]

2005-07-17 Thread Nathan Pinno
I use input() all the time. I know many people say it ain't safe, but whose going to use it to crash their own comp? Only an insane person would, or a criminal trying to cover his/her tracks. Sorry if I waded into the debate, but this debate originated from one of my posts. Nathan

Re: Another newbie question from Nathan.

2005-07-09 Thread Nathan Pinno
t make the code easier to read, but harder to code because I have to keep going to the top to read the menu. Not that fun, but necessary for a smooth program, I guess. Nathan Pinno "Steven D'Aprano" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > On

How to get 4 numbers from the user in one line for easy comparision?

2005-07-02 Thread Nathan Pinno
I saw that great idea from Steven, and I appreciate it. I think it will work. Just need to figure out how to get 4 numbers from the player on one line for easy comparison, e.g. telling whether the number is correct position and number, incorrect position and correct number, or both are incorr

Re: What's wrong with this code?

2005-07-02 Thread Nathan Pinno
ot;) if guess > number: print "Too high" elif guess < number: print "Too low" print "Just right" HTH, Nathan Pinno "John Machin" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Nathan Pinno wr

A brief question.

2005-07-02 Thread Nathan Pinno
Hi all,   Brief question for anyone who knows the answer, because I don't. Is there anyway to make Python calculate square roots?   Thanks, Nathan Pinnohttp://www.npinnowebsite.ca/ -- http://mail.python.org/mailman/listinfo/python-list

What's wrong with this code?

2005-07-02 Thread Nathan Pinno
Hi all, What's wrong with the following code? It says there is name error, that random is not defined. How do I fix it? # Plays the guessing game higher or lower. # Originally written by Josh Cogliati, improved first by Quique, then by Nathan Pinno. print "Higher or Lowe

Another newbie question from Nathan.

2005-07-01 Thread Nathan Pinno
Hi all. How do I make the computer generate 4 random numbers for the guess? I want to know because I'm writing a computer program in Python like the game MasterMind. Thanks. -- Nathan Pinno http://www.npinnowebsi

Re: I have a question.

2005-07-01 Thread Nathan Pinno
Thanks all. I needed to ask because I'm writing a couple of programs which require the computer to choose numbers at random thanks. Nathan Pinno "Jeremy Jones" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Nathan Pinno wrote: > >

I have a question.

2005-06-30 Thread Nathan Pinno
Hi all, Does Python have a random function? If so, can you show me an example using it? Thanks, Nathan Pinno http://www.npinnowebsite.ca/ -- Posted via UsenetRevolution.com - Revolutionary Usenet ** HIGH

Re: Python/IDLE - text in different colours

2005-06-28 Thread Nathan Pinno
Bill. The way is the click on view, then click script checker, or something like that. It will color code the text for you. Nathan "Bill Davy" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > To make life easier for my users, I'd like to colour my prompt string (as > ha

I need help figuring out how to fix this code.

2005-06-28 Thread Nathan Pinno
ct password has been supplied. The computers response will vary, # depending on the name inputted. print "Program Author: Nathan Pinno" print "ID# 2413448" print print "Program 3 - Loops and IF Conditions" print password = raw_input("Type in the passwo