Python Built in Functions |
Description |
Python abs() |
It returns the absolute value of a number, and the returned value is always positive. |
Python all() |
It returns true when all elements in an iterable are evaluated to be true orif there are no elements in an iterable. It returns false if any element is evaluated to be false. |
Python any() |
It checks if any element of an iterable is true. Unlike all(), it returns false if there are no elements in the iterable. |
Python ascii() |
This method returns a string containing printable representation. |
Python bin() |
This built in function in Python is used for converting an integer to a binary string. |
Python bool() |
This built in function in Python is used for converting a value to Boolean. |
Python bytearray() |
This built in function in python returns an array of the given byte size. |
Python bytes() |
This built in function in Python returns immutable bytes object. |
Python callable() |
This built in function Python is used for checking if the object is callable. |
Python chr() |
This built in python function returns a character (a string) from an integer. |
Python classmethod() |
This built in python function returns the class method for a given function. |
Python compile() |
This built in python function returns a Python code object. |
Python complex() |
This built in function in Python is used for creating a complex number. |
Python delattr() |
This built in function in Python is used for deleting an attribute from an object. |
Python dict() |
This built in function is used for creating a Python dictionary. |
Python dir() |
This built in python function tries to return the attributes of an object. |
Python divmod() |
This built in python function returns a tuple of quotient and remainder. |
Python enumerate() |
This built in python function returns an enumerate object. |
Python eval() |
This built in python function runs the Python code within a program |
Python exec() |
This built in python function is used for executing a dynamically created program. |
Python filter() |
This built in function in Python is used for constructing an iterator from the elements which are true. |
Python float() |
This built in function in Python is used for returning the floating-point number from a number or a string. |
Python format() |
This built in python function returns the formatted representation of a value. |
Python frozenset() |
This built in python function returns an immutable frozenset object. |
Python getattr() |
This built in python function returns the value of the named attribute of an object. |
Python globals() |
This built in python function returns the dictionary of a current global symbol table. |
Python hasattr() |
This built in python function returns a value that tells whether an object has a named attribute. |
Python hash() |
This built in python function returns the hash value of an object. |
Python help() |
This built in python function Invokes the built in help system |
Python hex() |
This built in function in Python is used for converting an integer to its hexadecimal form. |
Python id() |
This built in python function returns the identify of an object. |
Python input() |
This built in python function usually reads and returns a line of string. |
Python int() |
This built in python function returns an integer from a number or a string. |
Python isinstance() |
This function checks if an object is an instance of a class. |
Python issubclass() |
This checks if an object is a subclass of a class. |
Python iter() |
This function returns an iterator for an object. |
Python len() |
This function returns the length of an object. |
Python list() |
This function is used for creating a Python list. |
Python locals() |
This function returns the dictionary of a current local symbol table |
Python map() |
This function applies functions and returns a list. |
Python max() |
This function returns the largest element. |
Python memoryview() |
This function returns the memory view of an argument. |
Python min() |
This function returns the smallest element. |
Python next() |
This function retrieves the next element from an iterator. |
Python object() |
This function creates a featureless object. |
Python oct() |
This function converts an integer to its octal form. |
Python open() |
This function returns a file object. |
Python ord() |
This function returns a Unicode point for a Unicode character. |
Python pow() |
This function evaluates and returns x to the power of y. |
Python print() |
It is used for printing a given object. |
Python property() |
This function returns a property attribute. |
Python range() |
This function returns the sequence of integers between start and stop. |
Python repr() |
This function returns the printable representation of an object. |
Python reversed() |
This function returns the reversed iterator of a sequence. |
Python round() |
This function rounds a floating-point number to n digits places. |
Python set() |
This function returns a Python set. |
Python setattr() |
This function sets the value of an attribute of an object. |
Python slice() |
It is used for creating a slice object specified by the range() function. |
Python sorted() |
This function returns the sorted list from a given iterable. |
Python staticmethod() |
This function creates a static method from a function. |
Python str() |
This function returns an informal representation of an object. |
Python sum() |
This function is used for adding items of an Iterable. |
Python super() |
This function allows us to refer to the parent class by ‘super’. |
Python tuple() Function |
This function creates a tuple in python. |
Python type() |
This function returns the type of object. |
Python vars() |
This function returns the __dict__ attribute of a class. |
Python zip() |
This function returns an iterator of tuples. |
Python __import__() |
This function is an advanced function called by ‘import’. |