create different ssh key according the article Mac Set-Up Git
$ ssh-keygen -t rsa -C "your_email@youremail.com"
create different ssh key according the article Mac Set-Up Git
$ ssh-keygen -t rsa -C "your_email@youremail.com"
When hosting our web applications, we often have one public IP
address (i.e., an IP address visible to the outside world)
using which we want to host multiple web apps. For example, one
may wants to host three different web apps respectively for
example1.com
, example2.com
, and example1.com/images
on
the same machine using a single IP address.
How can we do that? Well, the good news is Internet browsers
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title>JS Bin</title> | |
</head> | |
<body> | |
<script id="jsbin-javascript"> |
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title>JS Bin</title> | |
</head> | |
<body> | |
<script id="jsbin-javascript"> |
function bubbleSort(items) { | |
console.log(items); | |
var length = items.length; | |
for (var i = (length - 1); i >= 0; i--) { | |
//Number of passes | |
for (var j = (length - i); j > 0; j--) { | |
console.log('items[j] = ' + items[j] + ' items[j - 1] = ' + items[j - 1]) | |
if (items[j] < items[j - 1]) { | |
//Swap the numbers | |
var tmp = items[j]; |
https://www.youtube.com/watch?v=86YAPbZmsRI&index=1&list=LLk0ldD0HZK090snvfuKTSWw | |
var arraylist = [3, 1, 4, 6, 5 , 12 , 13]; | |
arraylist.forEach(function(item,index){ | |
if(item%2 === 0){ | |
var divided = (item/2) * (item/2) | |
var big = divided + 1; | |
var small = divided - 1; | |
var foundSmall = false; |
function selectionSort(items) | |
{ | |
console.log(items) | |
var length = items.length; | |
for (var i = 0; i < length - 1; i++) | |
{ |
function selectionSort(items) | |
{ | |
console.log(items) | |
var length = items.length; | |
for (var i = 0; i < length - 1; i++) | |
{ | |
var min = i; | |
for (var j = i + 1; j < length; j++) | |
{ | |
console.log('items[j] ' + items[j] + ' items[min] ' + items[min]) |
function isAlphabet(x) | |
{ | |
return ( (x >= 'A' && x <= 'Z') || | |
(x >= 'a' && x <= 'z') ); | |
} | |
function reverse(str) | |
{ | |
console.log('INPUT ARRAY ' + str.join('')) |
function reverse(str) | |
{ | |
console.log('INPUT ARRAY ' + str.join('')) | |
var r = str.length - 1, l = 0; | |
while (l < r) | |
{ | |
swap(l, r); | |
l++; | |
r--; |