Register Now

Login

Lost Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

What is the mode of ‘a’ in the following R code?
a <- c(1,” a”, FALSE)

What is the mode of ‘a’ in the following R code?
a <- c(1,” a”, FALSE)
a) Numeric
b) Character
c) Integer
d) Logical

Answer: b
Explanation: All three elements can be expressed as a character. Both paste() and cat() will printout text to the console by combining multiple character vectors together. The original data are formatted as character strings so we convert them to R’s Date format for easier manipulation.

Join The Discussion