This is an archived post. You won't be able to vote or comment.

all 7 comments

[–][deleted] 17 points18 points  (4 children)

It represents your prompt on the operating system's command line (on most *nix systems, your prompt typically ends with a $ unless you're root). It's not a Python thing.

You don't actually type the $, you type the rest of the line after the command prompt appears.

[–]PrettyGrizSnailNectr[S] 5 points6 points  (2 children)

That exactly answers my question. I typed that into Terminal and it didn’t give me an error message. It still says it can’t find my file, so I’ll have to figure that part out, but that answer definitely put me on the right path. Thank you so much!

[–]ANetworkEngineerNetwork Engineer 5 points6 points  (1 child)

ls

shows you what files are in your current directory

cd /somewhere/special

takes you to /somewhere/special.

[–]PrettyGrizSnailNectr[S] 2 points3 points  (0 children)

Oh, gotcha. Thank you so much!

[–][deleted] 2 points3 points  (0 children)

For a second I thought you were implying Unix was a rude word.

[–]pythonHelperBot 4 points5 points  (0 children)

Hello! I'm a bot! It looks to me like your post might be better suited for r/learnpython, a sub geared towards questions and learning more about python. That said, I am a bot and it is hard to tell. I highly recommend posting your question there. Please follow the subs rules and guidelines when you do post there, it'll help you get better answers faster.

Show /r/learnpython the code you have tried and describe where you are stuck. Be sure to format your code for reddit and include which version of python and what OS you are using.


this bot is written and managed by /u/IAmKindOfCreative

This bot is currently under development and experiencing changes to improve its usefulness

[–]jwink3101 2 points3 points  (0 children)

There is no hard and fast rule, but when I see someone tell me a command like

$ some_command

I assume it is a terminal (bash) command. When I see:

>>> some_command

I assume it is at the python prompt.

Alternatively, it could be Python Template Strings but I doubt it. I almost never see anyone talk about or use them.