Containers are data structures that contain one or more objects. In Python, a c…


📦 Containers are data structures that contain one or more objects. In Python, a container object can contain objects of different types. For that matter, a container can contain other containers at any depth. Containers may also be called collections. 🐍 Sequences are containers that have inherent ordering among their items. For example, a string such as str = “hello world” is a sequence of Unicode characters h, e, l, etc. Note that there is no character data type in Python, and the expression “h” is actually a 1-character string.

basic sequence types are list, tuple, range, str, bytes bytearray and memoryview. Conversely, dict, set and frozenset are simply containers in which elements don’t have any particular order.
Source : devopedia.org
.
.
.
.
#pythonlearning #python #nerd #pythonprogramming #geeky #onlinelearning #courses #linux #basic



Source

Leave a Reply

Your email address will not be published. Required fields are marked *

PropellerAds
WhatsApp chat
Social media & sharing icons powered by UltimatelySocial
Share
Advertisements