#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jan 2014
    Posts
    14
    Rep Power
    0

    What is the best way to do this:


    Hi python3 What is the best way to go from say:

    testa.py too <click button> testb.py



    Thanks for any suggestions.
  2. #2
  3. Contributing User
    Devshed Demi-God (4500 - 4999 posts)

    Join Date
    Aug 2011
    Posts
    4,841
    Rep Power
    480
    Put
    Code:
    #! /usr/bin/python
    print('testb.py')
    into file testa.py.
    change the mode to executable.
    $ chmod +x testa.py

    type testa.py on the command line
    $ testa.py

    now press (with resounding `click') the <Enter> Button.
    answer works in unix with python3 installed in /usr/bin as python.
    [code]Code tags[/code] are essential for python code and Makefiles!
  4. #3
  5. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jan 2014
    Posts
    14
    Rep Power
    0
    what about inside the program?
    Not in the command line.
    oh I think you gave me the answer
    thanks

IMN logo majestic logo threadwatch logo seochat tools logo