Remote file download code is not working

import requests

def download_file(url, save_path):
response = requests.get(url)
if response.status_code == 200:
with open(save_path, ‘wb’) as f:
f.write(response.content)
print(“File downloaded successfully.”)
else:
print(f"Failed to download file. Status code: {response.status_code}")

Example usage:

url = “https://example.com/file.txt
save_path = “file.txt”
download_file(url, save_path)
This code is not working now please guide me.