make beep python 1

make beep python

import winsound
frequency = 2500  # Set Frequency To 2500 Hertz
duration = 1000  # Set Duration To 1000 ms == 1 second
winsound.Beep(frequency, duration)

Here is what the above code is Doing:
1. It’s importing the winsound module.
2. It’s setting the frequency to 2500 Hertz.
3. It’s setting the duration to 1000 milliseconds.
4. It’s playing the sound.

Similar Posts