Assignment

Write a function copycat with two mandatory parameters (source and destination) that each take a file location as the argument that needs to be passed to the function.

def copycat(source, destination)

After calling this function, the content of the source file must be copied into the destination file. If a file already existed at the location of the destination file, that content of the file must be overwritten. Otherwise, a new file must be created at the given destination. The function may make the assumption that the source file exists.

Example

>>> copycat('original.txt1', 'copycat.txt')
>>> copycat('shaw.txt2', 'shaw2.txt')