I am learning python for the past few weeks and already loving it. There are a bunch of amazing things you can do with python. Let me list some of them :
- It can help you download all the episodes of your favourite tv series/anime automatically.
- If you are a cricket lover , python will take care that you get desktop notifications of the live score .
- If you are a manga lover then you can download all the images of your manga automatically without the hassle of downloading the images one by one manually.
- It can help you organize a disorganized folder.
Before
After
- Don't miss out on the latest news.
For many days i want to organize my movies as per IMDB ratings but found it too lazy to do . So, I wrote a python script to accomplish this task.
Before
After
Yes, Python can really do some amazing tasks (at least for a person like me who is new to programming)
Update : Made another scripts that runs automatically everyday at 12 am(using crontab) , downloads the Bing image of the day and sets it as my wallpaper.
- #! /usr/bin/python3
- import requests
- from bs4 import BeautifulSoup
- import os
- import datetime
- dt = datetime.datetime.now()
- cd = str(dt.year)+'0'+str(dt.month)+str(dt.day)
- os.makedirs('Bing',exist_ok=True)
- url = 'Bing™ Wallpaper Gallery'
- sc = requests.get(url)
- soup = BeautifulSoup(sc.text,'lxml')
- image = soup.select('.cursor_zoom img')
- image_url = image[0].get('src')
- res = requests.get(image_url)
- with open(os.path.join('Bing',cd+'.jpg'),'wb') as file:
- file.write(res.content)
- os.system('gsettings set org.gnome.desktop.background picture-uri http://file:///home/radioactive/Bing/'+cd+'.jpg')
Update 2: If you're preparing for GRE/CAT or just wanna improve your vocabulary then this script will surely help you. This script displays a random word along with its meaning amongst the various words saved inside a text file after every five minutes as in the image below :
Another script that displays random quotes saved inside another text file .
You can find all the scripts and the text files here:
0 comments:
Post a Comment
Thank you for visiting our site!!