I wrote a little program that replaces all files called 'abcde' with the file in the directory from which you riun the program.&nbsp; However it does not find them (there is another one).<br> What have I done wrong :-<br> #this program copies the file x to all other places in the directory.<br> #however it does not go to the right places<br> def getfiles(file1,file2,top):<br> &nbsp;&nbsp;&nbsp; for root, dirs, files in os.walk(top):<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; for name in dirs:<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; for name in files:<br> &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; if name == file1:<br> &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; shutil.copy(file2,name)<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; print "copied one file"<br> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <br> import os<br> import shutil<br> #main<br> top = '/home'<br> a =
 os.getcwd()<br> filename = 'abcde'<br> file1 = filename<br> file2 = a+'/'+filename<br> getfiles(file1, file2,top)<br> print "finished"<br> <br> <br> <p>
                <hr size=1><font face="Arial" size="2">To help you stay safe and secure online, we've developed the all new <a href="http://us.rd.yahoo.com/mail/uk/taglines/default/security_centre/*http://uk.security.yahoo.com/"><b>Yahoo! Security Centre</b></a>.</font>