Courses
Tutorials
Jobs
Practice
Contests
Data Structure
Java
Python
HTML
Interview Preparation
Trending Now
DSA
Web Tech
Foundational Courses
Data Science
Practice Problem
Python
Machine Learning
JavaScript
System Design
Django
DevOps Tutorial
Java
C
C++
ReactJS
NodeJS
CP Live
Aptitude
Puzzles
Projects
Python | Pandas Quiz | Question 18
How can you reset the index of a Pandas DataFrame? (A)df.reset_index()(B)df.set_index()(C)df.index_reset()(D)df.index_reset() Answer: (A) ...
Read More
Python | Pandas Quiz | Question 13
Question: What is the purpose of the pivot_table() function in Pandas? (A)To create a new DataFrame(B)To pivot rows and columns in a DataFrame(C)To ...
Read More
Python | Pandas Quiz | Question 12
How can you handle missing values in a Pandas DataFrame? (A)Use df.fillna(value) to replace missing values(B)Use df.dropna() to remove rows with mis...
Read More
Python | Pandas Quiz | Question 7
How can you filter rows in a DataFrame based on a condition? (A)df.filter(condition)(B)df.select_rows(condition)(C)df[condition](D)df.filter_rows(co...
Read More
Python | Pandas Quiz | Question 5
How can you select a specific column from a DataFrame? (A)df.select_column("ColumnName")(B)df.get_column("ColumnName")(C)df["ColumnName"](D)df.colum...
Read More
Python | Pandas Quiz | Question 3
How can you read a CSV file into a Pandas DataFrame? (A)pd.load_csv()(B)pd.read_csv()(C)pd.import_csv()(D)pd.open_csv() Answer: (B) ...
Read More
Python | OOPs quiz | Question 8
Which keyword is used to achieve method overloading in Python? (A)overload(B)method(C)override(D)Python does not support method overloading Answer: ...
Read More
Python | OOPs quiz | Question 6
Inheritance in OOP allows a class to: (A)Combine multiple classes into one(B)Define multiple methods with the same name(C)Inherit properties and beh...
Read More
Python | OOPs quiz | Question 3
What is an instance variable in a class? (A)A variable shared among all instances of a class(B)A variable defined outside the class(C)A variable spe...
Read More
Python | While Loop Quiz | Question 17
In Python, can a while loop have multiple else blocks? (A)Yes(B)No(C)Only if the loop has multiple conditions.(D)Only if the loop uses nested if sta...
Read More
Python | While Loop Quiz | Question 16
What is the purpose of the assert statement in a while loop? (A)To terminate the loop.(B)To check if a condition is true and raise an error if not.(...
Read More
Python | While Loop Quiz | Question 13
What is the purpose of the continue statement in a while loop? (A)Terminates the loop.(B)Skips the remaining code in the loop and moves to the next ...
Read More
Python | While Loop Quiz | Question 8
What is the output of the following Python code?count = 0while count 3: print("Hello") count += 1else: print("Else block") (A)Prints "Hello" three ...
Read More
Python | Numpy Quiz | Question 12
How can you extract all elements from a NumPy array arr that are greater than 10? (A)filtered_elements = arr[arr 10](B)filtered_elements = np.extra...
Read More
Python | Pandas Quiz | Question 20
How can you save a Pandas DataFrame to a CSV file? (A)df.save_csv("filename.csv")(B)df.write_csv("filename.csv")(C)df.to_csv("filename.csv")(D)df.ex...
Read More
1
...
1601
1602
1603
...
11561