A. The lm() function is used to fit the linear regression model to the data in R language.