I want to remove any file which have extension of ".pdf" in r for the current working directory
file.remove(".pdf")
if(file.exists(paste0("Pic,".pdf"))){
clsfile<-paste0(Pic,".pdf")
unlink(clsfile, recursive=TRUE)
}