This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RWET Programming Exercise A | |
Text processing on the UNIX command line | |
--- | |
Step 1. Write the command to download the text file with the following URL to | |
your computer with the filename "frost.txt". (Hint: You'll need to use the | |
"curl" command, and possibly redirection with ">"). | |
Here's the URL: | |
http://rwet.decontextualize.com/texts/frost.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# RWET Programming Exercise B | |
# | |
# This worksheet is also a Python program. Your task is to read the | |
# task descriptions below and then write one or more Python statements to | |
# carry out the tasks. There's a Python "print" statement before each | |
# task that will display the expected output for that task; you can use | |
# this to ensure that your statements are correct. | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
from bs4 import BeautifulSoup | |
import sys | |
from selenium import webdriver #open webdriver for specific browser | |
from selenium.webdriver.common.keys import Keys # for necessary browser action | |
from selenium.webdriver.common.by import By # For selecting html code | |
import time | |
import os.path | |
def getQuotes(driver,quotes): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from __future__ import unicode_literals | |
import spacy | |
import quoteScraper | |
# from textblob import TextBlob | |
import random | |
nlp = spacy.load('en') | |
wordDict={'verbs':[],'nouns':[],'adjs':[],'advs':[],'prons':[]} | |
def getName(name): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import markdown | |
from flask import Flask, request,render_template | |
from flask import Markup | |
import quoteScraper as qs | |
import textGenerator as tg | |
app=Flask(__name__) | |
@app.route('/') | |
def home(): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title>Yin-yang</title> | |
<style id="jsbin-css"> | |
body{ | |
background: #666; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title>Yingyang pseudo class</title> | |
<style id="jsbin-css"> | |
body{ | |
background: #666; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title>JS Bin</title> | |
<style id="jsbin-css"> | |
*{ | |
padding:0; | |
margin:0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title>JS Bin</title> | |
<style id="jsbin-css"> | |
*{ | |
padding:0; | |
margin:0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title>JS Bin</title> | |
<style id="jsbin-css"> | |
header{ | |
height:50px; | |
background:#ddd; |
OlderNewer