<jupyter_start><jupyter_text>List and its default functions<jupyter_code># sum(list1)
    
list3 = [ 1, 2, 5, 8, 10] 
sum (list3)
#len(list)
list5 = [512, 'tomato', 'pizza',123]
len(list5)

#max(list)
list6 = [300, 600,750,1000]
max(list6)
#min(list)
min(list6)
# print(list)
list4 = [ 1, 2, 4, 3]
print (list4)<jupyter_output>[1, 2, 4, 3]<jupyter_text>Dictionary and its default functions<jupyter_code>#all(dict1)
dict1={'Name':'Ram','Age':30,'occupation':'Doctor'};
print(all(dict1))
dict2={'Name':'Ram','':30,'occupation':'Doctor'};
print(all(dict2))
#any(dict1)
dict1={'Name':'Ram','':30,'occupation':'Doctor'};
print(any(dict1))
# len(dict)
dict1 = {'Name': 'Ram', 'Age': 30};
print ("Length : %d" % len (dict1))
#sorted(dict1)
print(sorted(dict1))

#str(dict)
dict = {'Name': 'Ram', 'Age': 30};
print ("Equivalent String : %s" % str (dict))<jupyter_output>Equivalent String : {'Name': 'Ram', 'Age': 30}<jupyter_text>Sets and its default functions<jupyter_code>#Add

fruits = {"apple", "banana", "cherry"}

fruits.add("orange")

print(fruits)
#Copy

fruits = {"apple", "banana", "cherry"}

x = fruits.copy()

print(x)
#Discard

fruits.discard("banana")

print(fruits)
#Difference

x = {"apple", "banana", "cherry"}
y = {"google", "microsoft", "apple"}

z = y.difference(x)

print(z)
#Clear

fruits = {"apple", "banana", "cherry"}

fruits.clear()

print(fruits)<jupyter_output>set()<jupyter_text>Tuples and its default methods<jupyter_code>#index

friends = ('Steve', 'Rachel', 'Michael', 'Monica')
a= friends.index('Monica')
print(a)

#count

friends = ('Steve', 'Rachel', 'Michael', 'Monica')
a= friends.count('Steve')
print(a)
 #append
    
a=[10,20,30,40]
print("origional tuple:", a) 
a.append((50,60))
print("Tuple after appending:", a) 
#len

len(a)
#max

a=[10,20,30,40]
max(a)<jupyter_output><empty_output><jupyter_text>Strings and its default methods<jupyter_code>#find

friends = ('Hello, welcome here')
a= friends.find('welcome')
print(a)
#capitalize

friends = ('hello, welcome here')
a= friends.capitalize()
print(a)
#count

friends = "hello, welcome here"
a= friends.count('here')
print(a)
#center

friends = "welcome"
a= friends.center(20)
print(a)
#islower

friends = "Welcome"
a= friends.islower()
print(a)<jupyter_output>False
{'fraction_non_alphanumeric': 0.21076033792796797, 'fraction_numerical': 0.039573143619386394, 'mean_word_length': 7.1521739130434785, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 17, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '5', 'dir': 'jupyter-structured-clean-dedup', 'id': '458493', 'license': 'Apache-2.0', 'n_tokens_mistral': 1021, 'n_tokens_neox': 932, 'n_words': 194, 'path': 'First Assignment .ipynb', 'repo_name': 'Ankit5719/LetsUpgrade-Python-Essentials-Batch-7', 'size': '2249'}