472,958 Members | 1,858 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,958 software developers and data experts.

question on python syntax

If I type this in shell

$ ./yourfile.py 12:34 PM &

What does '$', '.', '/' and '& means in this succession? Note: 12:34
PM is a argument to the yourfile.py.

Sep 10 '07 #1
2 897
a.m. wrote:
If I type this in shell

$ ./yourfile.py 12:34 PM &

What does '$', '.', '/' and '& means in this succession? Note: 12:34
PM is a argument to the yourfile.py.
This not python syntax but Unix shell.

$ = shell prompt
../ = look for the program in my current working directory
yourfile.py = the program name
12:34 = argument 1
PM = argument 2
& = run in background
Sep 11 '07 #2
a.m. wrote:
If I type this in shell

$ ./yourfile.py 12:34 PM &

What does '$', '.', '/' and '& means in this succession? Note: 12:34
PM is a argument to the yourfile.py.
"$" is the shell prompting you to let you know it's ready for you to
type a command.

"./" says "look in the current directory for a file called ...".

Since the first token in the command contains a path separator ("/") the
normal mechanism of looking for the executable in each of the
directories in the current $PATH is not used [if you don't understand
this sentence, ignore it].

"&" says "run this command in the background and immediately prompt for
another command, instead of waiting for the command to finish like you
usually do".

Technically, by the way, 12:34 PM is *two* arguments to the yourfile.py,
not one.

regards
Steve
--
Steve Holden +1 571 484 6266 +1 800 494 3119
Holden Web LLC/Ltd http://www.holdenweb.com
Skype: holdenweb http://del.icio.us/steve.holden
--------------- Asciimercial ------------------
Get on the web: Blog, lens and tag the Internet
Many services currently offer free registration
----------- Thank You for Reading -------------

Sep 11 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

699
by: mike420 | last post by:
I think everyone who used Python will agree that its syntax is the best thing going for it. It is very readable and easy for everyone to learn. But, Python does not a have very good macro...
75
by: David MacQuigg | last post by:
Seems like we need a simple way to extend Python syntax that doesn't break existing syntax or clash with any other syntax in Python, is easy to type, easy to read, and is clearly distinct from the...
14
by: Uwe Mayer | last post by:
Hi, I know the python community is not very receptive towards extending the python syntax. Nevertheless I'd like to make a suggestion and hear your pro and cons. I want so suggest a...
2
by: yaffa | last post by:
dear python gurus, quick question on syntax. i have a line of code like this for incident in bs('tr', {'bgcolor' : '#eeeeee'}): what i want it to do is look for 'bgcolor' : '#eeeeee'...
2
by: waltbrad | last post by:
Hello. Been studying Python for about a week now. I did a quick read of the tutorial in the manual and I'm reading Programming Python by Mark Lutz. I'm still getting used to the Python syntax,...
2
by: neerashish | last post by:
Is there a good Python Syntax and mis-spelled variable and method name checker available. I have been programming in python for last 6 months and misspelled variables and method names have been...
3
by: Kinokunya | last post by:
Hi guys, My group and I will be working on our final year project, the scope to do a program/web-based application similar areas of functionalities like the PyLint and PyChecker; a Python syntax...
6
by: Daniel | last post by:
I hope this question is OK for this list. I've downloaded Rpyc and placed it in my site packages dir. On some machines it works fine, on others not so much. Here is one error I get when I try...
2
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 4 Oct 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
4
NeoPa
by: NeoPa | last post by:
Hello everyone. I find myself stuck trying to find the VBA way to get Access to create a PDF of the currently-selected (and open) object (Form or Report). I know it can be done by selecting :...
1
by: Teri B | last post by:
Hi, I have created a sub-form Roles. In my course form the user selects the roles assigned to the course. 0ne-to-many. One course many roles. Then I created a report based on the Course form and...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 1 Nov 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM) Please note that the UK and Europe revert to winter time on...
3
by: nia12 | last post by:
Hi there, I am very new to Access so apologies if any of this is obvious/not clear. I am creating a data collection tool for health care employees to complete. It consists of a number of...
0
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be focusing on the Report (clsReport) class. This simply handles making the calling Form invisible until all of the Reports opened by it have been closed, when it...
0
isladogs
by: isladogs | last post by:
The next online meeting of the Access Europe User Group will be on Wednesday 6 Dec 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, Mike...
2
by: GKJR | last post by:
Does anyone have a recommendation to build a standalone application to replace an Access database? I have my bookkeeping software I developed in Access that I would like to make available to other...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.