Python

Python Menu

Definition

The pop() method removes a random item from the set. This method returns the removed item.

Syntax

set.pop()

Parameters

No Parameters.

Examples:

persons = {"Arnel", "Marie", "Mark", "Jeff", "Ivan", "Mike"} j = persons.pop() print(persons) print(j)

Introduction

Python Basics

Python Advance

Data Science Python Tutorials

Python Functions and Methods