Sha256: 56de9dcaa084d3f9558f7c6ddfef390c45fa9b5a938066cdf5a7f8e30d6e7f20
Contents?: true
Size: 411 Bytes
Versions: 121
Compression:
Stored size: 411 Bytes
Contents
bob <- function(input) { # function bob takes a character input and responds # with a couple different sentences # strip white space input <- gsub("[[:space:]]","",input) if (input == "") { return("Fine. Be that way!") } if (toupper(input) == input && tolower(input) != input) { return("Whoa, chill out!") } if (endsWith(input,"?")) { return("Sure.") } return("Whatever.") }
Version data entries
121 entries across 121 versions & 1 rubygems