| license: mit |
| var a = [1,5,-5,2,-4, -6, 0, 2, 6]; | |
| var maxSub = function(a) { | |
| var subSums = []; | |
| // Create new array with largest subarray value of first | |
| subSums[0] = Math.max(a[0], 0); | |
| // Iterate through the array and create the new subproblems array for each value in the original. |
| <script type='text/javascript'> | |
| window.parent.onbeforeunload = function() { | |
| return "Don't Close"; | |
| }; | |
| </script> | |
| <h1>Test closing.</h1> |
| -- Select largest 20 from specific table | |
| SELECT table_name AS "Tables", round(((data_length + index_length) / 1024 / 1024), 2) "Size in MB" | |
| FROM information_schema.TABLES | |
| WHERE table_schema = "{TABLE NAME}" | |
| ORDER BY (data_length + index_length) | |
| DESC | |
| LIMIT 20; | |
| -- Select largest from ALL tables |
A curated list by Eric Elliott and friends. Suggest links in the comments below.
This is a very exclusive collection of only must-have JavaScript links. I'm only listing my favorite links. Nothing else makes the cut. Feel free to suggest links if you think they're good enough to make this list. The really curious should feel free to browse the comments to find other links. I can't guarantee the quality of links in the comments.
Some of these links are affiliate links, meaning that if you make a purchase, I might earn a little money. This has absolutely no bearing on whether or not links make the list. None, whatsoever. However, it does allow me more resources to fight poverty with code. Every little bit counts.
This is an adaptation of https://twitter.com/jasonneylon script.
In the terminal window, you can open your current repo (at the current branch) in your default browser.
My adaptation was adding options to view the commits, branches, pull requests or issues for the repo using one of the additional options (added support for wiki, settings, pulse, graphs, network):
[h] => View help
[c] => View commits
[c {SHA}] => View specific commit from commit SHA
[b] => View branches
##LEMP (CentOS) Stack Setup on Digital Ocean
These steps can be used to create a CentOS based droplet on Digital Ocean.
Source: Digital Ocean Guide
###Droplet, Users, SSH
- Create new droplet (without ssh key)
- SSH into the server with root@[ip] and the password that’s emailed.
- Change the root password and save in 1pass.
- Create new user:
adduser demo - Change new user’s pw:
passed demothen save in 1pass
- Install Mavericks via the App Store.