Python Forum

Full Version: window command window
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
(Aug-05-2021, 02:17 PM)RobertAlvarez424 Wrote: [ -> ]So this exe is for use in window 10 envoirment but actually can be a dos script or windows type script ? Opens cmd prompt window or used in window 10?
You seems a little lost on the basic stuff how OS(Windows) work,and i guess Python to.
Yes python.exe is for use in Windows as .exe is only for Windows OS,
Environment Variables Path is a convenient so Windows find version that you want use and command python and pip work from command line(cmd).
dos script and type script has nothing to with what we talk about here only how Python work on Windows.
(Aug-05-2021, 02:17 PM)RobertAlvarez424 Wrote: [ -> ]What is 'λ' character and how do you type this character with keyboard?
Do not now yet about pip. Does it package only dos type script
I do not type λ at all as i mention so i use cmder a much better version of cmd/powershell.
cmder insert λ automatic.

pip is the package installer for Python.
So if look at PyPi there is 319,780 projects.
If want use some of them in Python need to use pip.
Example with Requests that a lot people use.
# Install 
G:\div_code
λ pip install Requests
Collecting Requests
  Using cached requests-2.26.0-py2.py3-none-any.whl (62 kB)
Collecting charset-normalizer~=2.0.0
  Downloading charset_normalizer-2.0.4-py3-none-any.whl (36 kB)
Requirement already satisfied: idna<4,>=2.5 in c:\python39\lib\site-packages (from Requests) (2.10)
Requirement already satisfied: certifi>=2017.4.17 in c:\python39\lib\site-packages (from Requests) (2020.12.5)
Requirement already satisfied: urllib3<1.27,>=1.21.1 in c:\python39\lib\site-packages (from Requests) (1.26.3)
Installing collected packages: charset-normalizer, Requests
Successfully installed Requests-2.26.0 charset-normalizer-2.0.4

# Test that it work
G:\div_code
λ python
Python 3.9.5 (tags/v3.9.5:0a7dcbd, May  3 2021, 17:27:52) [MSC v.1928 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import requests
>>>
>>> r = requests.get('https://python-forum.io/')
>>> r.status_code
200
>>> r.encoding
'UTF-8'
>>> exit()

G:\div_code
snippsat, this is my first post for python questions, just starting out with python. This first post has a lot of info to learn from.
Thanks for your reply and everyone for you info too.
Pages: 1 2