Python Basic Commands

Veröffentlicht am: 01 Januar 1970
auf dem Kanal: gaming cyclone
92
6

Tech Session Playlist:    • Tech Sessions  
-------------------------------------------------------

Videos:
OBS screen recording tool :    • OBS screen recording tool  
Python Setup | Download | Install | Basic Programming :    • Python Setup | Download | Install | B...  
PyCharm IDE | Download Install Basic programming JetBrains :    • PyCharm IDE | Download Install Basic ...  
MySQL Server Setup | MySQL Workbench Setup | MySQL Basic Queries :    • MySQL Server | MySQL Workbench | MySQ...  

#gamingcyclone
#gaming_cyclone
‪@gamingcyclone‬
#python
#pythonprogramming
#commands
#pyhoncommands
#download
#install
#simpleprogramming
#techsession
#pythonsetup




-------------------------------------------------------
Python common commands

1) pip install packageName
pip install behave
behave --version


2) pip uninstall packageName
pip uninstall behave
behave --version


3) print command
print("Hello World!")


4) type command
x = 2
print(type(x))


x = "Testing Python"
print(type(x))


5) range command
range(start, stop, step)
print(range(10))


6) round command
print(round(3.14159, 2))


7) input command:
myYTChannelName = input("What is our YouTube Channel name: ")
print(myYTChannelName)


8) len command
len(myYTChannelName)


mylist=[1,2,3]
len(mylist)


myTupple=("abc", "def")
len(myTupple)


9)
x=10
y=20
if (x 'Use less than key here' y):
print ( "x is less than y")
else:
print ( "x is not less than y")

10) str1="Hello"
str2="World"
print (str1 + str2)
print (str1 + " " + str2)


11) str1.isalnum()
str2.isalnum()


str3="Hello!"
str3.isalnum()


str4="Hello123#"
str4.isalnum()


12) capitalize()
str5="hello"
str5.capitalize()


str5="hello world"
str5.capitalize()


13) find()
str6 = "We are learning Python commands. Are you with me?"
index = str6.find("are")
print(index)


14) count()
count=str6.count("are")
str6 = "We are learning Python commands. are you with me?"


count=str6.count("are")


15) upper case
upper_text = str6.upper()
print(upper_text)


16) lower case
lower_text = upper_text.lower()
print(lower_text)


17) append
print (mylist)
mylist.append(4)
print (mylist)


18) copy()
newCopy = mylist.copy()
print (newCopy)


19) insert()
list1 = [10, 20, 30]
list1.insert(2, 3)


20) pop()
list1.pop(0)


21) reverse()
list1.reverse()
print (list1)


22) list1.sort()
print (list1)


list1.sort(reverse=true)
print (list1)
-------------------------------------------------------


Auf dieser Seite können Sie das Online-Video Python Basic Commands mit der Dauer stunde minuten sekunde in guter Qualität ansehen, das der Benutzer gaming cyclone 01 Januar 1970 hochgeladen hat, den Link mit Freunden und Bekannten teilen, dieses Video wurde auf Youtube bereits 92 Mal angesehen und es wurde von 6 den Zuschauern gefallen. Viel Spaß beim Betrachtenden Zuschauern gefallen!