Welcome to ExamTopics
ExamTopics Logo
- Expert Verified, Online, Free.
exam questions

Exam Certified Associate Developer for Apache Spark All Questions

View all questions & answers for the Certified Associate Developer for Apache Spark exam

Exam Certified Associate Developer for Apache Spark topic 1 question 160 discussion

The code block shown below contains an error. The code block is intended to create a single-column DataFrame from Python list years which is made up of integers. Identify the error.

Code block:

spark.createDataFrame(years, IntegerType)

  • A. The column name must be specified.
  • B. The years list should be wrapped in another list like [years] to make clear that it is a column rather than a row.
  • C. There is no createDataFrame operation in spark.
  • D. The IntegerType call must be followed by parentheses.
  • E. The IntegerType call should not be present — Spark can tell that list years is full of integers.
Show Suggested Answer Hide Answer
Suggested Answer: D 🗳️

Comments

Chosen Answer:
This is a voting comment (?) , you can switch to a simple comment.
Switch to a voting comment New
5effea7
4 months, 2 weeks ago
Selected Answer: D
The answer is D
upvoted 1 times
...
azure_bimonster
9 months, 2 weeks ago
Selected Answer: D
D is right
upvoted 4 times
...
saryu
9 months, 3 weeks ago
Answer should be D
upvoted 2 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...