Bob Williams <li...@barrowhillfarm.org.uk> Wrote in message:

> 
>>> linkName1 = pathList[j][0:-3] + "mp3"
>> 
>> Isn't this exactly the same as pathList[j] ?
>> 
> Actually, no. pathList[j] can contain either .mp3 files or .flac
> files. In fact the main function of the script is to run all the flacs
> through lame to convert them into mp3s. If they are already mp3s, then
> a symlink will suffice.
> 
>>> 

If you're dealing with more than one extension,  and especially if
 they're different lengths,  consider using splitext
-- 
DaveA

_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor

Reply via email to