I am pretty new to Python. I've been trying to make a sciript that plays random WAV files from a specific folder whenever run. if I try a single wav file it works all fine but doesn't work with random/file. I have tried pygame and some other modules for audio but I ran issues with every single one. For example pygame refuses to open a WAV or MP3 file. When I print it I can see that it does choose random files but windows does a "bring" sound and doesn't play the audio. Really basic probably but I somehow cannot fix this. Thanks for the help.
import winsound
import random
import os
winsound.PlaySound(random.choice(os.listdir("D:/randomsoundfolder/dem/")), winsound.SND_ASYNC)