I have a large list with more than 100 elements. I would like to add 200 to the ID.
var <- c("ID66Session1_Date-2017-02-28__10-38.csv","ID66Session2_Date-2017-03-04__21-31.csv","ID66Session3_Date-2017-03-07__19-17.csv",
"ID66Session4_Date-2017-03-09__18-08.csv","ID66Session5_Date-2017-03-15__16-26.csv","ID66Session6_Date-2017-04-15__23-39.csv",
"ID6Session1_Date-2017-01-20__11-06.csv")
aim <- c("ID266Session1_Date-2017-02-28__10-38.csv","ID266Session2_Date-2017-03-04__21-31.csv","ID266Session3_Date-2017-03-07__19-17.csv",
"ID266Session4_Date-2017-03-09__18-08.csv","ID266Session5_Date-2017-03-15__16-26.csv","ID266Session6_Date-2017-04-15__23-39.csv",
"ID206Session1_Date-2017-01-20__11-06.csv")
I believe it's possible to solve this with grepl. But other solutions are also welcomed. I am looking for a handy and short code.