A Pen by Sonya Corcoran on CodePen.
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
| # Sources | |
| # johngibby.com/blog/How_to_deploy_your_meteor.js_app_on_Digital_Ocean | |
| # stackoverflow.com/questions/20117104/mongodb-root-user | |
| # digitalocean.com | |
| # Create a Digital Ocean Ubuntu 14.04 Droplet | |
| # You'll receive an email with your new IP and Password | |
| # e.g. | |
| # Droplet Name: dropletname | |
| # IP Address: 000.000.000.000 |
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
| // performs the specified action on each item in the array | |
| Array.prototype.forEach = function (fnAction) { | |
| var l = this.length; | |
| for (var i = 0; i < l; ++i) { | |
| fnAction(this[i]); | |
| } | |
| } | |
| // returns an array containing the items matching the filter | |
| Array.prototype.where = function (fnFilter) { |
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
| var request = require('request'); | |
| var app = require('express')(); | |
| var results; | |
| function logRes(){ | |
| console.log(results); | |
| } | |
| app.get('/storeData', minion1(req,res){ | |
| readResult(logRes) |
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
| # SSL self signed localhost for rails start to finish, no red warnings. | |
| # 1) Create your private key (any password will do, we remove it below) | |
| $ openssl genrsa -des3 -out server.orig.key 2048 | |
| # 2) Remove the password | |
| $ openssl rsa -in server.orig.key -out server.key |
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
| <?xml version="1.0" ?> | |
| <kml xmlns="http://www.opengis.net/kml/2.2"> | |
| <Document> | |
| <Name>USyd Buildings</Name> | |
| <Placemark> | |
| <name>1-3 Ross Street</name> | |
| <description>Campus: Camperdown<br>Building Code: K06</description> | |
| <Point> | |
| <coordinates>151.184341,-33.884591</coordinates> | |
| </Point> |
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
| def example(a) # function a | |
| b = [] # b is an empty array | |
| for i in 0..a # for every (i)ndex in the range 0 to a (or 4 in this example) | |
| b[i] = i # not clear how this works. I think it's a shorthand for .push | |
| # More importantly, I don't know why you have to assign the position of the index in the array to i | |
| end # end of loop | |
| return b #return b | |
| end # end of function |
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
| #include <unistd.h> | |
| void ft_putchar(char c) | |
| { | |
| write(1, &c, 1); | |
| } | |
| void ft_print_comb2(void); | |
| int main() |
OlderNewer