Advertisement
gavin19

rnd file py

Jul 31st, 2011
188
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.17 KB | None | 0 0
  1. import os
  2. from random import choice
  3. x = input("Path : ")
  4. lst = []
  5. for root, dirs, files in os.walk(x):
  6.    for name in files:
  7.        lst.append(name)  
  8. print(choice(lst))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement