Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

random pick any file from directory python

import os, random
random.choice(os.listdir("C:")) #change dir name to whatever
Comment

PREVIOUS NEXT
Code Example
Python :: check string similarity python 
Python :: is machine learning hard 
Python :: how to get frequency of each elements in a python list 
Python :: print current time hours and minutes in python 
Python :: axis font size matplotlib 
Python :: delete unnamed 0 columns 
Python :: How to print list without for loop python 
Python :: install models python 
Python :: python add 1 to count 
Python :: pip vs anaconda venv 
Python :: how to get latitude and longitude from address in python 
Python :: matplotlib add space between subplots 
Python :: open choose files from file explorer python 
Python :: python levenshtein distance 
Python :: getting dummies and input them to pandas dataframe 
Python :: tensot to numpy pytorch 
Python :: python get image dimensions 
Python :: brownie from wei to ether 
Python :: python diamond print 
Python :: python remove first and last character from string 
Python :: python blender select object by name 
Python :: remove nan from list python 
Python :: save list python 
Python :: Could not build wheels for opencv-python which use PEP 517 and cannot be installed directly 
Python :: tkinter boilerplate 
Python :: django get superuser password 
Python :: how to update sklearn using conda 
Python :: python cd to script directory 
Python :: python read xls 
Python :: pandas groupby as new column 
ADD CONTENT
Topic
Content
Source link
Name
2+9 =