Download the latest version of Python from python.org
Create a folder on your C: drive and call it RedditBackground. Add the file RedditBackground.py in that folder.
To run the RedditBackground script, open the command line and point to C:\RedditBackground. Now run this command:
python RedditBackground.py subredditName
For example, to get the top rated image of /r/spaceporn, type:
python RedditBackground.py spaceporn