Created
April 16, 2018 07:47
-
-
Save vankesteren/20959d95629387b440ffd9f9f5fdef42 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ints <- function(start, end) { | |
| if (start > end) return(NULL) | |
| return(c(start, ints(start + 1, end))) | |
| } |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
even shorter
i<-function(s,e)if(s<=e)c(s,i(s+1,e))