my_answers <- c('S+', 'C++', 'Python', 'Matlab', 'Javascript') #check_answers(my_answers)
Within the same script, show the current working directory (see function getwd
, as in print(getwd())
). Now, change your working directory to Desktop (Desktop) and show the following message on the prompt screen: 'My desktop address is ....'
. Tip: use and abuse of RStudio's autocomplete tool to quickly find the desktop folder.
current_dir <- getwd() print(current_dir) new_dir <- '~/Desktop/' # this is probably C:/Users/USERNAME/Desktop for Windows setwd(new_dir) cat(paste0('My desktop address is ', getwd()))
extype: string
exsolution: r mchoice2string(c(TRUE, FALSE, FALSE, FALSE, FALSE), single = TRUE)
exname: "getwd"
exshuffle: TRUE
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.