Which operator is used to assign a value to a variable in R?

  • ->
  • <-
  • =
  • All of the above
The '<-' operator is commonly used in R for assignment, although the '=' operator can also be used. However, '<-' is generally preferred because it makes the code more readable and avoids confusion with the '=' operator used for passing arguments to functions.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *