x <- rstring("A random integer in [1,100]: <%=sample(1:100, size=1)%>
")
cat(x)
# Passing arguments
x <- rstring("A random integer in [1,<%=K%>]: <%=sample(1:K, size=1)%>
", args=list(K=50))
cat(x)
Run the code above in your browser using DataCamp Workspace