Class 12 Informatics Practices
Data Handling Using Python Pandas – 1 (Set 2)
Multiple Choice Questions
Data Handling Using Pandas – I MCQs
Topics Covered : Series
21. A Series is a one-dimensional array containing a sequence of values of _________ data type
a. int
b. float
c. string
d. any (int, float, list, string)
22. Series is having by default numeric data labels. The value of data labels is starting from _________ and ended at number of values – 1.
a. 0
b. 1
c. -1
d. n
23. The data label associated with a particular value is called its _______.
a. Item
b. Value
c. Column
d. Index
24. Can we assign values of other data types as index to a Series object.
a. Yes
b. No
c. Yes, but only numeric types
d. Yes, but only numeric and boolean types.
25. The given figure, is an example of _________.
a. Series
b. DataFrame
c. Array
d. List
26. A series can be created by using ___________.
a. Scalar Value
b. List
c. NumPy Array
d. Dictionary
e. All of these
27. In the given code , a series is created from ______ values.
>>> ser1 = pd.Series(20, index = range(4))
a. Scalar Value
b. List
c. NumPy Array
d. Dictionary
28. In Series, Index can be specified ____________.
a. explicitly
b. implicityly
c. Both a and b
d. None of these
29. If You do not explicitly specify an index for the data values, then by default indices range from ______ through _______.
a. 1 , N – 1
b. 0, N
c. 0, N – 1
d. 1, N
30. In the given code , Identify the value of Indices.
>>> ser1 = pd.Series(20, index = range(4))
a. 1, 2, 3, 4
b. 0, 1, 2, 3
c. 1, 2, 3
d. 0, 1, 2
31. Can you assign user-defined labels to the index and use them to access elements of a Series.
a. Yes
b. No
32. In the given code , a series is created from ______ values.
>>> ser1 = pd.Series([20, 16, 76, 34] )
a. Scalar Value
b. List
c. NumPy Array
d. Dictionary
33. Can you use strings or letters as Indices in Series?
a. Yes
b. No
34. Which argument can we use in the Series( ) method to specify the index values explicitly?
a. INDEX
b. Index
c. index
d. indices
35. Identify the data type of index in the given code?
>>> ser1 = pd.Series([2,6,4,8], index = [1,2,5,6])
a. int64
b. float64
c. string
d. object
36. Identify the data type of index in the given code?
>>> ser1 = pd.Series([2,6,4,8], index = [1.5, 2.6, 5.8, 6.4 ] )
a. int64
b. float64
c. string
d. object
37. Identify the data type of index in the given code?
>>> ser1 = pd.Series( [2, 6, 4, 8 ] , index = [True, False, False, True] )
a. integer
b. boolean
c. string
d. object
38. Identify the data type of index in the given code?
>>> ser1 = pd.Series( [2, 6, 4, 8 ] , index = [‘Ram’, ‘Amrit’, ‘Tanmay’, ‘Anjeev’ ] )
a. integer
b. boolean
c. string
d. object
39. Identify the data type of index in the given code?
>>> ser1 = pd.Series( [2, 6, 4, 8 ] , index = [ 1 , ‘A’, True, 5.9 ] )
a. integer
b. float
c. string
d. object
40. An element of Series can be access by _________.
a. Index
b. Value
c. Both a and b
d. None of these