diff options
Diffstat (limited to 'Lib/aifc.py')
-rw-r--r-- | Lib/aifc.py | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/Lib/aifc.py b/Lib/aifc.py index e28c5c0..bc82f48 100644 --- a/Lib/aifc.py +++ b/Lib/aifc.py @@ -453,7 +453,7 @@ class Aifc_read: kludge = 0 if chunk.chunksize == 18: kludge = 1 - print 'Warning: bad COMM chunk size' + print('Warning: bad COMM chunk size') chunk.chunksize = 23 #DEBUG end self._comptype = chunk.read(4) @@ -518,11 +518,11 @@ class Aifc_read: # a position 0 and name '' self._markers.append((id, pos, name)) except EOFError: - print 'Warning: MARK chunk contains only', - print len(self._markers), - if len(self._markers) == 1: print 'marker', - else: print 'markers', - print 'instead of', nmarkers + print('Warning: MARK chunk contains only', end=' ') + print(len(self._markers), end=' ') + if len(self._markers) == 1: print('marker', end=' ') + else: print('markers', end=' ') + print('instead of', nmarkers) class Aifc_write: # Variables used in this class: @@ -939,16 +939,16 @@ if __name__ == '__main__': sys.argv.append('/usr/demos/data/audio/bach.aiff') fn = sys.argv[1] f = open(fn, 'r') - print "Reading", fn - print "nchannels =", f.getnchannels() - print "nframes =", f.getnframes() - print "sampwidth =", f.getsampwidth() - print "framerate =", f.getframerate() - print "comptype =", f.getcomptype() - print "compname =", f.getcompname() + print("Reading", fn) + print("nchannels =", f.getnchannels()) + print("nframes =", f.getnframes()) + print("sampwidth =", f.getsampwidth()) + print("framerate =", f.getframerate()) + print("comptype =", f.getcomptype()) + print("compname =", f.getcompname()) if sys.argv[2:]: gn = sys.argv[2] - print "Writing", gn + print("Writing", gn) g = open(gn, 'w') g.setparams(f.getparams()) while 1: @@ -958,4 +958,4 @@ if __name__ == '__main__': g.writeframes(data) g.close() f.close() - print "Done." + print("Done.") |