Skip to content

Instantly share code, notes, and snippets.

View stripedpurple's full-sized avatar
💭
📷

Nixua stripedpurple

💭
📷
View GitHub Profile
http://www.oreilly.com/data/free/files/2014-data-science-salary-survey.pdf
http://www.oreilly.com/data/free/files/2015-data-science-salary-survey.pdf
http://www.oreilly.com/data/free/files/Data_Analytics_in_Sports.pdf
http://www.oreilly.com/data/free/files/advancing-procurement-analytics.pdf
http://www.oreilly.com/data/free/files/ai-and-medicine.pdf
http://www.oreilly.com/data/free/files/analyzing-data-in-the-internet-of-things.pdf
http://www.oreilly.com/data/free/files/analyzing-the-analyzers.pdf
http://www.oreilly.com/data/free/files/architecting-data-lakes.pdf
http://www.oreilly.com/data/free/files/being-a-data-skeptic.pdf
http://www.oreilly.com/data/free/files/big-data-analytics-emerging-architecture.pdf
/*
Consider this puzzle
------------------------------------------------------------
- Start from the number 1
- Repeatedly, either adding 5 or multiplying by 3, an infinite amount of new numbers can be produced.
- How would you write a function that, given a number, tries to find a sequence of such additions and multiplications that produce that number?
- For example, the number 13 could be reached by first multiplying by 3 and then adding 5 twice
- Can number 15 be reached?
*/
@stripedpurple
stripedpurple / rasp-mosquitto.sh
Created December 30, 2015 15:25
Installs MQTT broker (Mosquitto) on raspberry pi
#!/bin/sh
# Check to see if the script was run as Root
if [[ "$EUID" -ne 0 ]]; then
echo "Sorry, you need to run this as root"
exit 1
fi
cd /etc/apt/sources.list.d/
debVer=`lsb_release -a | grep -i codename | awk '{print $2}'`
if [ '$debVer' == 'jessie' ]; then
@stripedpurple
stripedpurple / bulkUploadToImgur.sh
Created November 18, 2015 06:42
Add this function to your .bash_profile to upload all the images in a directory to imgur.com
function uploadImage {
ext=$1
if [ "$ext" == "help" ]; then
printf "Description:\n\tUploads all images in directory of extension type specified to imgur.com\nExample:\n\tuploadImage jpg\nFile Types:\n\tPEG, PNG, GIF, APNG, TIFF, BMP, PDF, XCF (GIMP). Please note that TIFF, BMP, PDF and XCF (GIMP) will be converted to PNG on upload. PNGs over 756KB are automatically converted to JPG.\n\n\tImgur does not currently support WEBM, MP4, or GIFV uploads. They will need to be converted before upload.\n"
else
for f in *".$1";
do
printf "$f\t"