Comece agoraComece grátis

Transforming Multiple Columns

You want to transform your data from kilometers to miles for an American client. You want do it in an efficient way that applies the same transformation to multiple columns.

Este exercicio faz parte do curso

Introduction to Polars

Ver curso

exercicio interativo prático

Tente este exercicio completando este código de exemplo.

# There are 1.609 kilometers in a mile
MILES_TO_KILOMETERS = 1.609

# Convert top_speed and range to miles
print(ev_df.with_columns(____/MILES_TO_KILOMETERS))
Editar e Executar Código