Given a vector goals <- c(2, 3, 1, 0, 4,2,0,1,4,3) that represents the number of goals scored per game, answer the following questions. After completing this activity using RStudio share the link or upload your file to Canvas.

goals <- c(2, 3, 1, 0, 4,2,0,1,4,3)

What is the total number of goals scored?

sum(goals)
## [1] 20

We can see the total goals scored was 20.

What is the average number of goals scored per game?

mean(goals)
## [1] 2

We can see the average number of goals scored was 2

What is the maximum number number of goals scored in a single game?

max(goals)
## [1] 4

We can see the maximum number of goals scored in a single game was 4

What is the minimum number of goals scored in a single game?

min(goals)
## [1] 0

We can see the minimum number of goals scored in a single game was 0