Databricks Interview Question

using array build some things