title: How do i play a sound in python 3?
body: <p>I wanted to write a python script to play a sound (recorded using windows recorder)! </p>
  
  <p>I read pygame can do the job and installed pygame! But I don't know how to write a code that plays a sound from a specific path! I have to play an audio file located at <code>C:\Users\Asdf\Documents\Audio.wav</code></p>
  
  <p>I tried a script from here <a href="http://pythonprogramming.net/adding-sounds-music-pygame/" rel="nofollow">http://pythonprogramming.net/adding-sounds-music-pygame/</a></p>
  
  <pre><code>import pygame
  crash_sound = pygame.mixer.Sound("crash.wav")
  </code></pre>
  
  <p>But then I get an error message:</p>
  
  <blockquote>
    <p>Traceback (most recent call last):   File "", line 1, in
    
        crash_sound = pygame.mixer.Sound("crash.wav") AttributeError: 'module' object has no attribute 'mixer'</p>
  </blockquote>
  
  <p>So how do I write the script to play that Audio.wav file using pygame? </p>
  
  <p>I am using Python 3.4 64 bit version!</p>