Category: Python

Python List

List function The list() function return the elements of a list, tuple, dictionary, set or string. Examples Example 1 >>> x = 1, 23, 'tuple' >>> list(x) [1, 23, 'tuple'] >>> y = ['c', 'list', 5, 8] >>> list(y) ['c', 'list',...

Python MAX

Max function The max() function return the maximum number in an iterable or the maximum number of two or more arguments. Examples Example 1 >>> max(5,7) 7 >>> max('5', '3', '8') '8' >>> x = 3 >>> y = 10 >>>...

Python MIN

Min function The min() function return the minimum number in an iterable or the minimum number of two or more arguments. Examples Example 1 >>> min(2,3) 2 >>> min('7', '3', '8') '3' >>> x = 12 >>> y = 15 >>>...

Python Ord

Ord function The ord() function return an integer representing the ASCII code for a given string(the string is an ASCII character). The ord() function is the opposite of chr(). Examples Example 1 >>> ord('A') 65 >>> ord('B') 66 >>> ord('a') 97...

Python Pow

Pow function The pow(arg1, arg2[arg3]) function return the arg1 to the power arg2. If arg3 is present, then the function return the arg1 to the power arg2, modulo arg3. Examples Example 1 >>> pow(2,2) 4 >>> pow(2,3) 8 >>> pow(2,3,2) 0...