x <- 5
x > 13
## [1] FALSE
x <- c(5, 14, 10, 22)
x > 13
## [1] FALSE TRUE FALSE TRUE
12 == 12
## [1] TRUE
12 <= c(12, 11)
## [1] TRUE FALSE
12 %in% c(12, 11, 8)
## [1] TRUE
x <- c(12, NA, 11, NA, 8)
is.na(x)
## [1] FALSE TRUE FALSE TRUE FALSE
x <- c(5, 14, 10, 22)
# how many elements in x are greater than 13?
sum(x > 13)
## [1] 2