All quizzes
Free quiz · 22 questions in the bank

PySpark quiz

Test your PySpark knowledge with a free interactive quiz — 22 questions with answers and explanations. No signup needed to play.

Question 1/5Score 0

How do you cache a DataFrame in memory to avoid recomputing it across multiple actions?

Questions in this quiz
  1. How do you cache a DataFrame in memory to avoid recomputing it across multiple actions?
  2. What does `df.repartition(n)` do?
  3. What is an RDD (Resilient Distributed Dataset)?
  4. What is a "broadcast variable" in PySpark?
  5. What is an "accumulator" in PySpark?
  6. What does `rdd.map(func)` do?
  7. What does `rdd.reduceByKey(func)` do on a key-value pair RDD?
  8. How do you convert a pandas DataFrame into a Spark DataFrame?
  9. What does `df.filter(condition)` (or the equivalent `df.where(condition)`) do?
  10. What is Py4J's role in PySpark's architecture?
  11. What does `rdd.collect()` do, and why should it be used carefully on large datasets?
  12. What is the relationship between PySpark's DataFrame API and Spark SQL?
Gaps to close?
Read the curated PySpark notes — core concepts, patterns, interview prep.
PySpark notes

More quizzes

.NET.NET MAUIAbsintheAccessibilityActixActix Web