Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
Aisha Wall
# Example of data structure - list oldList = [2, 6, 'jim', True] newList = [False, 'contents', 78] # based on the index - start from 0 listCities = ['Doha', 'Dafna', 'Wakra'] newCity = ['Duhail'] newList = listCities + newCity # Method examples for list DS # - .append(item) # - .insert(pos, item) listCities.insert(2,newCity[0]) # Example of data structure - string str1 = "Wakrr Wakra Wakra." str2 = "DOHA" print str1 print str1.upper() print str2.lower() print str1.find('ra') # Method examples for string DS # - .upper() # - .lower() # - .find(item)
run
|
edit
|
history
|
help
0
how far light travels in centimeters in one nanosecond
binary_4
Replace
check if any permutations of a word is a palindrome - python
NewFoodTipper
16
PyClass
Nama Bulan Python
Python learning
fb_series