Advertisement
Guest User

YT link

a guest
Feb 27th, 2020
116
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 0.28 KB | None | 0 0
  1. link = gets
  2.  
  3. if link =~ /watch/
  4.   x = link.split('')
  5.   v = x[32..]
  6.   v = v.join("").rstrip.rstrip
  7.  
  8.   print v
  9. else
  10.   x = link.split('')
  11.   v = x[17..]
  12.   v = v.join("").rstrip.rstrip
  13.  
  14.   print v
  15. end
  16.  
  17. #https://www.youtube.com/watch?v=ID_NUMBER
  18. #https://youtu.be/ID_NUMBER
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement