Python/Python%20MCQS%20-%20Data%20type%20in%20python Sample Test,Sample questions

Question:
Empty list in python is made by ?

1.l=[]

2.l=list()

3.Both of the above

4.None of the above

Posted Date:-2019-06-04 11:39:11


Question:
How we can convert the given list into the set ?

1.list.set()

2.set.list()

3.set(list)

4.None of the above

Posted Date:-2019-06-04 11:43:55


Question:
If we change one data type to another, then it is called

1.Type conversion

2.Type casting

3.Both of the above

4.None of the above

Posted Date:-2019-06-04 11:33:14


Question:
If we try to access the item outside the list index, then what type of error it may give ?

1.List is not defined

2.List index out of range

3.List index out of bound

4.No error

Posted Date:-2019-06-04 11:49:41


Question:
In which data type, indexing is not valid ?

1.list

2.string

3.dictionary

4.None of the above

Posted Date:-2019-06-04 11:46:33


Question:
In which of the following data type, duplicate items are not allowed ?

1.list

2.set

3.dictionary

4.None of the above

Posted Date:-2019-06-04 11:41:43


Question:
l=[1,2,3,4,8,1.2], which type of data type is this ?

1.set

2.list

3.tuple

4.integer

Posted Date:-2019-06-04 11:53:01


Question:
l=[1,2,3,4],
then l[3] is ?

1.1

2.2

3.3

4.4

Posted Date:-2019-06-04 11:47:01


Question:
l=[1,2,3,4], then l[-2] is ?

1.1

2.2

3.3

4.4

Posted Date:-2019-06-04 11:47:55


Question:
l=[9,3,7,6,1,2,0], then l[100] is

1.2

2.9

3.6

4.Error

Posted Date:-2019-06-04 11:48:25


Question:
What is list data type in Python ?

1.collection of integer number

2.collection of string

3.collection of same data type

4.collection of different data type

Posted Date:-2019-06-04 11:37:47


Question:
What is type casting in python ?

1.declaration of data type

2.destroy data type

3.Change data type property

4.None of the above

Posted Date:-2019-06-04 11:35:31


Question:
Which of the following can convert the string to float number ?

1.str(float,x)

2.float(str,int)

3.int(float(str))

4.float(str)

Posted Date:-2019-06-04 11:50:54


Question:
which of the following function are used to convert the string into the list ?

1.map()

2.convertor()

3.split()

4.lambda

Posted Date:-2019-06-04 11:56:38


Question:
Which of the following is not the data type in python ?

1.List

2.Tuple

3.Set

4.Class

Posted Date:-2019-06-04 11:32:22


Question:
Which of the following is the data type possible in python?

1.int

2.list

3.dictionary

4.All of the above

Posted Date:-2019-06-04 11:31:38


Question:
Which of the following is the example of the type casting ?

1.int(2)

2.str(2)

3.str(list)

4.All of the above

Posted Date:-2019-06-04 11:36:39


Question:
Which of the following is the list in python ?

1.l=[]

2.l=list()

3.l=[1,2,3]

4.All

Posted Date:-2019-06-04 11:38:27


Question:
Which of the sequence are valid in the set data type in python ?

1.1,1,1,1,1,1

2.2,3,4,5,6,1,2

3.1,2,3,4,5,6

4.None of the above

Posted Date:-2019-06-04 11:40:46


Question:
x=3.123, then int(x) will give

1.3.1

2.0

3.1

4.3

Posted Date:-2019-06-04 11:51:24


More MCQS

  1. Python MCQS - Function
  2. Python MCQS - GUI in python
  3. Python MCQS - Operators
  4. Python MCQS - Data type in python
  5. Python MCQS - loops in python
  6. Python MCQS - Numpy
  7. Python MCQS - sqlite3
  8. Python MCQS - Library
  9. Python MCQS - Pandas
  10. Python MCQs
  11. Dictionary Python MCQ set 1
  12. Dictionary Python MCQ set 2
  13. MCQ For Python Fundamentals
  14. MCQ Introduction to Python Section 1
  15. MCQ Introduction to Python Section 2
  16. MCQ Introduction to Python Section 3
  17. MCQ on Flow of Control in Python Set 1
  18. MCQ on Flow of Control in Python Set 2
  19. MCQ on Python String Set 1
  20. File Handling in Python section 1
  21. File Handling in Python section 2
  22. Python Functions MCQS Set 1
  23. Python Functions MCQS Set 2
  24. MCQ on List in Python
  25. Pandas MCQ Questions Set 1
  26. Pandas MCQ Questions Set 2
  27. Tuple MCQ in Python
  28. Python dataframe MCQ
  29. Python Mcq Set 1
  30. Python Mcq Set 2
  31. Python Mcq Set 3
  32. Python Mcq Set 4
  33. Python Mcq Set 5
  34. Python Mcq Set 6
  35. Python Mcq Set 7
  36. Python Mcq Set 8
  37. Python Mcq Set 9
  38. Python Mcq Set 10
  39. Python Mcq Set 11
  40. Python Mcq Set 12
  41. Python Mcq Set 13
  42. Python Mcq Set 14
  43. Python Mcq Set 15
  44. Python Mcq Set 16
  45. Python Mcq Set 17
  46. Python Mcq Set 18
  47. Python Mcq Set 19
  48. Python Mcq Set 20
  49. Python Mcq Set 21
  50. Python MCQ
  51. Python MCQ Questions with Answer
  52. Test
Search
R4R Team
R4Rin Top Tutorials are Core Java,Hibernate ,Spring,Sturts.The content on R4R.in website is done by expert team not only with the help of books but along with the strong professional knowledge in all context like coding,designing, marketing,etc!