Like, bhaiya has create a class Zrange and when he calls the class it returns only list as an iterable. But Iterable can be tuples and dictionary. How can we make the iterable as a python tuples and dict?
Regading Iterable
Hi @shreyashgupta68 over here class Zrange is used to create an iterable objects, so when bhaiya calls the class it returns the iterable object which is just a collection of numbers form 0 to n-1 … once the iterable object is created it is type casted to list… over there u can also type cast it to tuple it won’t promt an error but for dictionary code has to be slighlty changed as it have key value pair.
like this we can create an interable object for dictionary with key and value to be same
Hopes this might helps😀