Author: Krishna B

Python – Is Tuples Read-Only ???

Tuples in Python are read only lists which means after a tuple is created it does not allow any of its elements to be modified. In this post we are going to see that tuple elements can be modified. Following are the examples.  From the above example it is evident that we are able to update […]

Python – What Extend method can do ???

You might have used extend method in Lists where it can be used to add multiple elements to a list object. But what else it can be do is the topic of our discussion here.To add multiple elements to a list using extend method is technically not a right way of understanding the method functionality. […]

Deep Dive into Tuples — Python

Tuples are read-only lists whereafter it is created with some elements you cannot add any elements into it. Hence it is called Read Only Lists. Following is an example showing a tuple and how it behaves when you add an element after it is created. Github link: https://github.com/bvvkrishna/Tuples/blob/master/Tuple%20Basic%20Example.ipynb Can Tuples be modified? Tuples can also be […]

Sets the Maths one — Python

Sets are mutable data type objects containing a collection of elements. It is an unordered collection and contains only unique objects in it. Being an unordered data structure it will not record element position or the order elements are inserted into it. The other name for sets are Value-less dictionaries and they are internally implemented […]

Dictionary Walk Through— Python

Dictionary is a mapping data structure containing a set of elements where each element is a key-value pair. Dictionaries in other programming languages are called as Hashes or Associative arrays. Dictionaries are indexed by keys rather than integer numbers like in lists or tuples. An example of a simple dictionary is as follows. Alternative Ways […]