Python Regular Expressions

A Regular Expression (RegEx) represents a group of characters that forms a search pattern used for matching/searching within strings. Python Regular Expressions is a special sequence of characters that helps you match/find other strings or sets of strings, using a specialized syntax held in a pattern. There is a module named “re” which provides python regular expressions support. It comprises functions … Read more

List pop() Method

In Python Built-In List pop() method is used to removes and return the last object from the given list. Syntax: There is 1 Parameter used in the list pop() method: obj An optional parameter, and the index of the object to be removed from the given list. Example:

List remove(obj) Method

In Python Built-In List remove(obj) method is used to search for the given element in the list and removes the first matching element from the list. Syntax: There is 1 Parameter used in the list remove(obj) method: obj Object to be removed from the given list. Example:

List reverse() Method

In Python Built-In List reverse() method is used to reverse objects of the given list in place. Syntax: No Parameter is used in list reverse() method. Example:

List sort() Method

In Python Built-In List sort() method is used to sort objects of given list, and use compare func if given. Syntax: No Parameter is used in list sort() method. Example:

Tuple len(tuple) Function

In Python Built-In Tuple len(tuple) function is used to returns the number of elements in the given tuple. Syntax: There is 1 Parameter used in Tuple len(tuple) Function: list for which the number of elements to be counted. Example:

Lists cmp() Function

In Python Built-In Lists cmp() function is used to compare 2 elements in the given list. Syntax: There are 2 parameters used in Lists cmp() Function : list1 The first list to be compared and list2 The second list to be compared. Example:

List len(list) Function:

In Python Built-In List len(list) function is used to returns the number of elements in the given list. Syntax: There is 1 Parameter used in Lists len(list) Function: list for which the number of elements to be counted. Example:

List max(list) Function:

In Python Built-In List max(list) function is used to return the elements from the given list with maximum value. Syntax: There is 1 Parameter used in List max(list) Function: list from which max value to be returned. Example:

List min(list) Function:

In Python Built-In List min(list) function is used to returns the elements from the given list with minimum value. Syntax: There is 1 Parameter used in List min(list) Function: list from which min value to be returned. Example: