This file contains hidden or 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
convert -density 150 input.pdf -colorspace gray -linear-stretch 3.5%x10% -blur 0x0.5 -attenuate 0.25 +noise Gaussian -rotate 0.5 temp.pdf | |
gs -dSAFER -dBATCH -dNOPAUSE -dNOCACHE -sDEVICE=pdfwrite -sColorConversionStrategy=LeaveColorUnchanged dAutoFilterColorImages=true -dAutoFilterGrayImages=true -dDownsampleMonoImages=true -dDownsampleGrayImages=true -dDownsampleColorImages=true -sOutputFile=output.pdf temp.pdf |
This file contains hidden or 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 selenium import webdriver | |
from selenium.webdriver.common.by import By | |
from selenium.webdriver.support.ui import WebDriverWait | |
from selenium.webdriver.support import expected_conditions as EC | |
from bs4 import BeautifulSoup | |
driver = webdriver.Firefox(executable_path='C:\\Users\\steal\\workplace\\scrape\\geckodriver.exe') | |
for i in range(1, 24): |
This file contains hidden or 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
127.0.0.1 api.ak.facebook.com | |
127.0.0.1 api.connect.facebook.com | |
127.0.0.1 api.facebook.com | |
127.0.0.1 app.facebook.com | |
127.0.0.1 apps.facebook.com | |
127.0.0.1 ar-ar.facebook.com | |
127.0.0.1 badge.facebook.com | |
127.0.0.1 blog.facebook.com | |
127.0.0.1 connect.facebook.com | |
127.0.0.1 connect.facebook.net |
This file contains hidden or 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 xlrd import open_workbook | |
import numpy as np | |
import statsmodels.api as sm | |
''' | |
HOW TO RUN | |
Make sure FILE_NAME matches the name of the spreadsheet (change any spaces to underscores). | |
Make sure DEPEDENT_VAR_COL_NUMBER is set to the number of the column where your depedent variable is. |
This file contains hidden or 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
You left your computer unlocked and your friend decided to troll | |
you by copying a lot of your files to random spots all over your file | |
system. | |
This file contains hidden or 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 collections import defaultdict | |
import string | |
# You're running a pool of servers where the servers are numbered sequentially starting from 1. Over time, any given server might explode, in which case its server number is made available for reuse. When a new server is launched, it should be given the lowest available number. | |
# Write a function which, given the list of currently allocated server numbers, returns the number of the next server to allocate. In addition, you should demonstrate your approach to testing that your function is correct. You may choose to use an existing testing library for your language if you choose, or you may write your own process if you prefer. | |
# For example, your function should behave something like the following: | |
# >> next_server_number([5, 3, 1]) |
This file contains hidden or 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
#!/usr/bin/env python | |
""" | |
Created on Thu Mar 22 15:12:20 2018 | |
@author: Cubie, Tom Aarsen | |
""" | |
import requests, time | |
from multiprocessing import Pool |
This file contains hidden or 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
spurdo() { | |
sed "s/kek/geg/gI;s/epic/ebin/gI;s/america/clapistan/gI;s/right/rite/gI;s/your/ur/gI;s/\./ :DD/gI;s/'//gI;s/,/XDD/gI;s/wh/w/gI;s/th/d/gI;s/af/ab/gI;s/ap/ab/gI;s/ca/ga/gI;s/ck/gg/gI;s/co/go/gI;s/ev/eb/gI;s/ex/egz/gI;s/et/ed/gI;s/iv/ib/gI;s/it/id/gI;s/ke/ge/gI;s/nt/nd/gI;s/op/ob/gI;s/ot/od/gI;s/po/bo/gI;s/pe/be/gI;s/pi/bi/gI;s/up/ub/gI;s/va/ba/gI;s/ck/gg/gI;s/cr/gr/gI;s/kn/gn/gI;s/lt/ld/gI;s/mm/m/gI;s/nt/dn/gI;s/pr/br/gI;s/ts/dz/gI;s/tr/dr/gI;s/bs/bz/gI;s/ds/dz/gI;s/es/es/gI;s/fs/fz/gI;s/gs/gz/gI;s/ is/iz/gI;s/as/az/gI;s/ls/lz/gI;s/ms/mz/gI;s/ns/nz/gI;s/rs/rz/gI;s/ss/sz/gI;s/ts/tz/gI;s/us/uz/gI;s/ws/wz/gI;s/ys/yz/gI;s/alk/olk/gI;s/ing/ign/gI;s/ic/ig/gI;s/ng/nk/gI" \ | |
<<< "${@:-$(cat /dev/stdin)}" | |
} |
This file contains hidden or 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
journalctl --vacuum-size=100M #remove all logs, only retain 100mb | |
pacman -Scc #remove all package installation files (obsolete and current) | |
pacman -S bleachbit #if not installed already | |
bleachbit -c system.* | |
pacrmorphans #zsh alias to remove orphaned packages | |
sudo paccache -ruk0 #remove all that aren't installed |
This file contains hidden or 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
// copied from here: https://jsfiddle.net/icefrogcode/kqdx7cyb/1/ | |
// ALL CREDITS GO TO ICEFROG | |
// the associated html page for reference: | |
// <div> | |
// <h1> | |
// Google Advertisment Scanner | |
// </h1> | |
// <p> | |
// <b>What does it do?</b> This script opens 2 tabs in your browser and automatically searches the top 1000 keywords for Google Ad Sense on Google. Google Ad Sense is the Advertisement service google runs. | |
// </p> |
NewerOlder