What are vectors?
Vector operations
Indexing and filtering
Simple analysis
Summary
28. Exercise 1

Instruction

Last year, Versico held a corporate 10-kilometer race called "Race to the Top", with the goal of promoting team spirit and a healthy lifestyle. All 12 employees prepared for this contest by gathering once a week and running 10 kilometers together. They recorded their running times each week, and at the end of each practice session, they compared their times to their previous records to see how much they improved.

Exercise

Let's do some simple data analysis to see how much the Versico employees improved their running times by practicing over a period of six months. We've created two vectors for you.

The vector first_running_time stores the number of minutes it took each employee to run 10 kilometers during their first practice session. The vector race_time stores the number of minutes it took each employee to complete the actual "Race to the Top" competition.

Create a vector called running_time_improved that stores the number of minutes by which the Versico employees improved their running times between their first practice session and the actual "Race to the Top" competition.

Stuck? Here's a hint!

Calculate the difference first_running_time - race_time.