tags:

views:

35

answers:

1

i have list similar to this

m=[['qw','wew','23','C:/xyz/s.wav'],['qw','wew','23','C:/xyz/s2.wav'],['qw','wew','23','C:/xyz/s1.wav']]

now i want to these files

win=wave.open(m[0][3],'rb')

it is giving error how can i use this in this way... i want to take the files name from the list

please suggest???

A: 

do this:

m = [['qw','wew','23','C:/xyz/s.wav'],['qw','wew','23','C:/xyz/s2.wav'],['qw','wew','23','C:/xyz/s1.wav']]
fname = m[0][3]
print 'fname is', repr(fname)
win = wave.open(fname, 'rb')

and show us (using copy/paste into an edit of your question) everything that is printed, especially
(1) the result of print 'fname is', repr(fname)
(2) the ERROR MESSAGE

John Machin
oh thanks its working now..fineone more i just want to know how to convert str(x) into float type
kaushik
@kaushik: (1) thanks for what??? what was the problem? what did you do to fix it?(2) if you really can't extrapolate from the int(x) answer to another of your questions, then ask a SEPARATE question.
John Machin