Guest User

Untitled

a guest
Jan 20th, 2019
64
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.13 KB | None | 0 0
  1. function rec(x) {
  2. if (x.length === 0) {
  3. return ""
  4. }
  5. return x[x.length -1] + rec(x.slice(0,x.length-1))
  6. }
  7.  
  8. rec("hello")
Add Comment
Please, Sign In to add comment