Create a function that takes in a name as a string argument, and prints out "Hello name"

585    Asked by Dannasahi in Data Science , Asked on Nov 21, 2019
Answered by Danna sahi

Let us create a function to print out “Hello Sam”

hello_you <- function(name){

    print(paste('Hello',name))

}

hello_you('Sam')

Output

[1] "Hello Sam"



Your Answer

Interviews

Parent Categories