Vectors nulls in vectors (solution)

Exercise

Cut and paste the following vector into your assignment. Then use code to print the requested values related to the vector. You’ll need to use na.rm = TRUE to ignore the null values.

  1. The smallest number in the numbers vector
  2. The largest number in the numbers vector
  3. The average of the numbers in the numbers
  4. The sum of the values in the numbers vector
Output solution
[1] 5
[1] 42
[1] 16.4
[1] 82