the labels or the indexes. And the right side column indicates the numbers. In the case of series1, we did not provide any indexes for the pandas.Series() constructor. So, it prints the default labels or the indexes that start from 0.
In the case of series2, we are providing the indexes [“First”, “Second”, “Third”, “Fourth”, “Fifth”] as input. So, if we print series2, it will output the following:
First 1 Second 2 Third 3 Fourth 4 Fifth 5 dtype: int64
So, the complete output of the given program will be:
0 1 1 2 2 3 3 4 4 5 dtype: int64 First 1 Second 2 Third 3 Fourth 4 Fifth 5 dtype: int64








































0 Comments