S.No Built in Function or Built in Methods Description String List Tuple

You might also like

Download as doc, pdf, or txt
Download as doc, pdf, or txt
You are on page 1of 1

S.

No
Built in function or
built in methods
Description String List Tuple
1 Append()
Add an item to the end
of the list

2 Insert(i,x)
Insert an item at a given
position
3 Join()
joins the elements of the
list into a single string
4 List(seq) onvert a string to a list
! "emove()
"emove the first item
from the list
# "epla$e(old,ne%&'$o(nt))
"et(rn a $op* of the
string %ith all
o$$(rren$es of s(+string
old repla$ed +*
new(optional argument-
Count)
, -op(i)
"emove the item at the
given position in the list,
and ret(rn it
. /ort()
/ort the items of the list,
in pla$e
0 "everse()
"everse the elements of
the list, in pla$e
11 2ind(sub', start', end)))
"et(rn the lo%est
index in the string %here
s(+string sub is fo(nd
11 Len()
3o find the
length
12 /plit()
splitting a string into a
m(lti4element list
13 o(nt(x)
"et(rn the
n(m+er of times x
appears in the list
14 Islo%er()
"et(rn tr(e if all
$ased $hara$ters in the
string are lo%er$ase
1! swapcase()
"et(rn a $op* of
the string %ith (pper$ase
$hara$ters $onverted to
lo%er$ase and vi$e versa

You might also like