Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8877673
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T19:31:19+00:00 2026-06-14T19:31:19+00:00

I was reading programming python 4th edition by Mark Luze, Oreilly, by teaching myself.

  • 0

I was reading programming python 4th edition by Mark Luze, Oreilly, by teaching myself.
There’s an example on how to fork a child process, which I do not quite understand:

os.execlp('python', 'python', 'child.py', #other args#)

In an interactive shell(like bash), I know I can type python child.py #args# to ask python interpreter to run child.py with args.
Why are there TWO ‘python’ in the execlp() function? If I put only one python in the function, I would get an error complainting cannot find file or directory, which is the 1st args of child.py

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T19:31:20+00:00Added an answer on June 14, 2026 at 7:31 pm

    The first argument is the program to execute (found on the PATH). The rest are the sys.argv arguments to the program.

    The first such argument is the program name used to invoke it, and the display value used in the OS process list. It is the value of sys.argv[0] in a python script.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Recently I started reading Mark Lutz's Programming Python - Fourth Edition. I am a
I'm reading Mark Lutz's Programming Python 3rd editon , and I'm puzzled with a
I am reading Programming in Objective-C 4th Ed. by Stephen G. Kochan. In the
tl:dr how does decoupling work? could need some little example I'm reading Programming Ruby
I'm reading Tutorial on Network Programming with Python , and in this document the
I have been reading Programming Computer Vision with Python by Jan Erik Solem which
I've been reading tutorials about Curses programming in Python, and many refer to an
I am currently going though the process of learning C++ though reading programming books.
An example from the book Core Python Programming on the topic Delegation doesn't seem
I was just reading through Learning Python by Mark Lutz and came across this

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.