articlesDf = articlesDf.groupby("col").count()
B. 4, 5
C. 2, 5, 3
D. 5, 2
E. 2, 3, 4
F. 2, 5, 4
Answer: E
Explanation:
Correct code block:
articlesDf = articlesDf.select(explode(col(‘attributes’)))
articlesDf = articlesDf.groupby(‘col’).count()
articlesDf = articlesDf.sort(‘count’,ascending=False).select(‘col’)
Output of correct code block:
+——-+
| col|
+——-+
| summer|
| winter|
| blue|
| cozy|
| travel|
| fresh|
| red|
|cooling|
| green|
+——-+
Static notebook | Dynamic notebook: See test 2,
Latest Databricks Certified Associate Developer for Apache Spark 3.0 Dumps Valid Version with 180 Q&As
Latest And Valid Q&A | Instant Download | Once Fail, Full Refund