CertyRush
Đang tải...
C CertyRush
Câu hỏi free preview

Câu 25: Databricks Certified Associate Developer for Apache Spark

Which of the following code blocks returns a new DataFrame with a new column employeesPerSqft that is the quotient of column numberOfEmployees and column sqft, both of which are from DataFrame storesDF? Note that column employeesPerSqft is not in the original DataFrame storesDF.

Nội dung câu hỏi

Which of the following code blocks returns a new DataFrame with a new column employeesPerSqft that is the quotient of column numberOfEmployees and column sqft, both of which are from DataFrame storesDF? Note that column employeesPerSqft is not in the original DataFrame storesDF.

Các lựa chọn

Đáp án được giữ gọn theo nhãn A, B, C, D trong phần bình chọn tương tác.

  1. A. storesDF.withColumn("employeesPerSqft", col("numberOfEmployees") / col("sqft")) — đáp án hiện tại
  2. B. storesDF.withColumn("employeesPerSqft", "numberOfEmployees" / "sqft")
  3. C. storesDF.select("employeesPerSqft", "numberOfEmployees" / "sqft")
  4. D. storesDF.select("employeesPerSqft", col("numberOfEmployees") / col("sqft"))
  5. E. storesDF.withColumn(col("employeesPerSqft"), col("numberOfEmployees") / col("sqft"))

Cộng đồng

0 bình luận công khai. Tên thành viên được ẩn một phần.

Chưa có bình luận. Mở giao diện tương tác để bắt đầu thảo luận.

Câu hỏi liền kề