# R for Beginners — Lesson 1
# Run these examples in RStudio. Only base R is needed.

# Arithmetic
2 + 2
10 * 5
20 / 4

# Assignment
number_of_students <- 20
number_of_students + 5
number_of_students  # Still 20

# Mean of invented practice scores
scores <- c(6, 8, 10, 12, 14)
mean(scores)

# Exercise solution
practice_values <- c(5, 10, 15)
mean(practice_values)

# Optional: read sample-data.csv after downloading it to the same
# working directory as this script. In RStudio, check getwd() first.
# practice_data <- read.csv("sample-data.csv")
# mean(practice_data$score)

