0

I read some information about changing file extension using python code. I have giant folder with several file types like .csv, .json and .sf1. All I need to do is to replace all .sf1 to .txt file. Any suggested code in python would help.

  • Wondering why your question has been favourited twice, this has been asked to the point of exhaustion. Please try a minimal amount of googling before asking a question here. – cs95 Nov 08 '17 at 04:32

1 Answers1

0

import os

os.rename('foo.bar', 'foo.baz')

Neil Anderson
  • 1,265
  • 12
  • 19