This is content converted from Markdown!
Here's a JSON sample:
{
"foo": "bar"
}
report = {} | |
worksheet = None | |
if (len(list_of_dicts) == 0): | |
report["value1"] = ('No elements') | |
else: | |
# 0 Monday | |
# 1 Tuesday | |
# 2 Wednesday | |
# 3 Thursday |
import click | |
import requests | |
from urllib.parse import urlparse,parse_qs | |
routes = {'TSA':['30','01','09'],'HSB':['02','03','08'],'LNG':['03'],'SWB':['01','04','05'],'DUK':['30'],'NAN':['02']} | |
url = 'http://orca.bcferries.com:8080/cc/marqui/sailingDetail.asp?route={0}&dept={1}' | |
@click.command() | |
@click.option('-d','--depart', type=click.Choice(['TSA', 'HSB','LNG','SWB','DUK','NAN']), prompt='Departure', | |
help='Where the ferry is departing.') |
# meant to be run as a cronjob | |
# used to aggreagate data output from hoowmanypeople around and send to server | |
from datetime import datetime | |
import requests | |
def main(start,end): | |
now = datetime.now() | |
list_of_list_of_macs = [] |
import requests | |
import urllib | |
import json | |
url = """ https://www.purpleair.com/json?&sensorsActive=168&orderby=L """ | |
Search_Term = "Kamloops" | |
req = urllib.request.Request( |
import sys | |
from requests import get | |
from bs4 import BeautifulSoup | |
# Put in your class details. It scans TRU bookstore to get ISBN | |
# It uses the ISBN to search Libgen to get MD5 | |
# It then downloads from Libgen using the MD5 | |
def make_request(url): | |
headers = { | |
'Host': 'thebookstore.tru.ca', | |
'Connection': 'keep-alive', |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Evan's Templating Site</title> | |
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.0/css/bootstrap.min.css"> | |
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script> | |
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.0/js/bootstrap.min.js"></script> | |
<script id="json" src="template.json"></script> | |
</head> | |
<body> |
grid = [ | |
[0,None,None,None], | |
[0,0,None,None], | |
[-1,0,0,None], | |
[-1,-1,0,0], | |
] | |
seq = ['U','G','A','U'] | |
def match(i,j): |
<html> | |
<head> | |
<style> | |
h1 { | |
font-family: Calibri; | |
} | |
</style> | |
</head> | |
<body> | |
<h1>Hello World!</h1> |
#fizz buzz 5 ways | |
def fizzbuzz_1(): #classic | |
for i in range(1,101): | |
if i % 15 == 0: | |
print('fizzbuzz') | |
elif i % 3 == 0: | |
print('fizz') |