[DTW] Week09

I made a bot that tells you today’s fortune based on your horoscope. [fortune.py] import requests from bs4 import BeautifulSoup def get_horoscope(s): signs = [“ARIES”, “TAURUS”, “GEMINI”, “CANCER”, “LEO”, “VIRGO”, “LIBRA”, “SCORPIO”, “SAGITTARIUS”, “CAPRICORN”, “AQUARIUS”, “PISCES”] sign = signs.index(s) + 1 url = ‘https://www.horoscope.com/us/horoscopes/general/horoscope-general-daily-today.aspx?sign=’ + str(sign) html = requests.get(url).text soup = BeautifulSoup(html, ‘html.parser’) f = […]

[DTW] Week06

This week’s assignment is about manipulating images scrapped from the web. I scrapped the image results of ‘Chris Van Allsburg’, who is my favourite illustrator, from Pinterest, made a tiled image with those scrapped jpegs and added a text title to it. Since I only wanted his illustration images, I had to delete other images […]

[DTW] Week02

  The assignment this week: Scrap the web and then create a list with the material you collected.   I chose urbandictionary.com for this assignment. This site provides multiple pages and each page contains a list of words and expressions. The parameter for accessing a specific page is ‘page’. I used the following python code […]

[DTW] Week 1

This week’s assignment was to critique three websites by altering their content using browser’s developer tools. I chose Amazon.com, Twitter.com  and   [Amazon.com] I changed the pictures and the titles of the products, altered my name in the user information section to ‘Pushover’, modified the subscription date to B.C. 2000. I also changed the titles […]