Quantcast

Got Homework?

Connect with other students for help. It's a free community.

  • across
    MIT Grad Student
    Online now
  • laura*
    Helped 1,000 students
    Online now
  • Hero
    College Math Guru
    Online now

Here's the question you clicked on:

55 members online
  • 0 replying
  • 0 viewing

rachelPDX Group Title

How do I run a program once I've written it? Is it with Python Console? If so, where do I find this console? I'm working on a PC. I think I've got ps0, just want to test it.

  • one year ago
  • one year ago

  • This Question is Open
  1. karim279 Group Title
    Best Response
    You've already chosen the best response.
    Medals 1

    If you're using IDLE(Python GUI), just hit F5 or choose Run Module from the Run tab, and call the function you want to test in python shell (just type its name with parameters).

    • one year ago
  2. systemghost Group Title
    Best Response
    You've already chosen the best response.
    Medals 1

    If you haven't found IDLE yet, it's tucked away in the "idlelib" folder in "Lib", inside your Python folder. I'm using Windows, so mine was the Windows batch file called "idle". If there's a more obvious way to open it, I haven't found it. Once you do that, you can go into the File tab there and open a new window, where you can write and execute programs. You can run your program just as karim described.

    • one year ago
  3. lowfriction Group Title
    Best Response
    You've already chosen the best response.
    Medals 0

    I was frustrated with this at first too as they didn't seem to mention this detail in the lectures or I missed it. Slightly important detail.

    • one year ago
  4. carlsmith Group Title
    Best Response
    You've already chosen the best response.
    Medals 0

    You should be able to open a console and enter python /path/to/file.py You don't have to use IDLE to run a script.

    • one year ago
  5. rachelPDX Group Title
    Best Response
    You've already chosen the best response.
    Medals 0

    Thanks everyone! Yeah, I'm pretty new. I didn't reallize I had to write programs in a new window. I thought I could write them in the shell. But now I'm a total pro and on to ps1! ;)

    • one year ago
  6. JackEDowns Group Title
    Best Response
    You've already chosen the best response.
    Medals 0

    Whew, thanks for asking this Rachel! I came back here after about 50 minutes of reading the wiki to find out I need to open a new window and not run it in the console window! I am thinking this is a bad sign for me already lol

    • one year ago
  7. rachelPDX Group Title
    Best Response
    You've already chosen the best response.
    Medals 0

    Well, I didn't. So you shouldn't worry about it either :)

    • one year ago
  8. JohnSilva Group Title
    Best Response
    You've already chosen the best response.
    Medals 0

    Had the same probl ;) here's the code for my problem set 0: http://dpaste.com/800737/ But when i run it after i saved as a new file, the last print statment runs so fast one can hardly say that it displays name and age so im not sure if i solve it or not..

    • one year ago
    • Attachments:

See more questions >>>

Your question is ready. Sign up for free to start getting answers.

spraguer (Moderator)
5 → View Detailed Profile

is replying to Can someone tell me what button the professor is hitting...

23

  • Teamwork 19 Teammate
  • Problem Solving 19 Hero
  • You have blocked this person.
  • ✔ You're a fan Checking fan status...

Thanks for being so helpful in mathematics. If you are getting quality help, make sure you spread the word about OpenStudy.

This is the testimonial you wrote.
You haven't written a testimonial for Owlfred.