(Requirement: homebrew should already be installed) This will install opencv3 on a mac for use with python2
$ brew tap homebrew/science
$ brew install opencv3 --with-python3
$ mkdir -p /Users/rushi/Library/Python/2.7/lib/python/site-packages
| Palette 1: | |
| Teal? Green-ish?: | |
| Main: #2bcabb | |
| Darker border: #047F6F | |
| Blue: | |
| Main: #008ae6 | |
| Darker border: #004573 |
| --My initial solution, but I realized that maybe repeatedly calling maximum wasn't good | |
| profits :: [Int] -> [Int] | |
| profits (x:y:ys) = (maximum (xs) - x) : profits (xs) | |
| where xs = y:ys | |
| profits _ = [] | |
| --My updated solution that is slightly more complex | |
| --But it keeps track of the current maximum until that current maximum is outdated | |
| profits' :: [Int] -> Int -> [Int] | |
| profits' (x:y:ys) cm = |
(Requirement: homebrew should already be installed) This will install opencv3 on a mac for use with python2
$ brew tap homebrew/science
$ brew install opencv3 --with-python3
$ mkdir -p /Users/rushi/Library/Python/2.7/lib/python/site-packages
| submitPush() { | |
| git add . | |
| git commit -m "$1" | |
| git push origin master | |
| cwd=$(pwd) | |
| cd ../ | |
| git add . | |
| git commit -m "$1" |
| (require 'package) | |
| (add-to-list 'package-archives | |
| '("melpa-stable" . "http://stable.melpa.org/packages/") t) | |
| (package-initialize) | |
| ;; Stuff for Haskell | |
| (add-hook 'haskell-mode-hook 'turn-on-haskell-indentation) |
| `timescale 1ps/1ps | |
| module main(); | |
| initial begin | |
| $dumpfile("cpu.vcd"); | |
| $dumpvars(0,main); | |
| end | |
| // clock |
| (require 'package) | |
| (custom-set-variables | |
| ;; custom-set-variables was added by Custom. | |
| ;; If you edit it by hand, you could mess it up, so be careful. | |
| ;; Your init file should contain only one such instance. | |
| ;; If there is more than one, they won't work right. | |
| '(package-archives | |
| (quote | |
| (("gnu" . "http://elpa.gnu.org/packages/") | |
| ("melpa-stable" . "http://stable.melpa.org/packages/")))) |
| #include "stdint.h" | |
| #include "debug.h" | |
| #include "thread.h" | |
| #include "ide.h" | |
| #include "bobfs.h" | |
| void check(const char* name, StrongPtr<Node> f) { | |
| if (f.isNull()) { | |
| Debug::printf("*** 0 %s is null\n",name); | |
| return; |
| # Usage: | |
| # python3 script.py input.txt output.txt | |
| # (don't forget to take names out of input.txt when you're done with them) | |
| import sys | |
| import requests | |
| from bs4 import BeautifulSoup | |
| baseURL = 'https://directory.utexas.edu/index.php' | |
| def getEmailFromName(name): |
| # Custom prompt | |
| #--------------- | |
| # Get the Git branch | |
| parse_git_branch() { | |
| git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/' | |
| } | |
| # Make Git branch a variable | |
| branch=$(git branch | sed -n -e 's/^\* \(.*\)/\1/p') | |
| # Includes custom character for the prompt, path, and Git branch name. |