This file contains 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
function check(n) { | |
var history = "(" + n; | |
var number = n; | |
while (number > 3) { | |
if ((number % 2)=== 0) { | |
number = number / 2; | |
history += ")/2" | |
} | |
else { | |
number = number - 5; |
This file contains 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
//map for objects | |
Object.defineProperty(Object.prototype, 'map', { | |
value: function(f, ctx) { | |
ctx = ctx || this; | |
var self = this, result = {}; | |
Object.keys(self).forEach(function(k) { | |
result[k] = f.call(ctx, self[k], k, self); | |
}); | |
return result; | |
} |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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 oldGeo = [{ | |
'name': 'Wels', | |
'address': '', | |
'number': '', | |
'zip': '4600', | |
'city': 'Wels', | |
'lat': '48.19043815', | |
'lon': '14.07081485', | |
'urls': [{ | |
'cat': 'Raststationen', |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
Every 2,0s: cat /proc/mdstat Thu Apr 21 15:57:58 2016 | |
Personalities : [raid1] | |
md0 : active raid1 sdb1[0] sda1[1] | |
312438784 blocks super 1.2 [2/2] [UU] | |
[=================>...] resync = 88.7% (277137600/312438784) finish=15.4min speed=38042K/sec | |
bitmap: 1/3 pages [4KB], 65536KB chunk | |
unused devices: <none> |
This file contains 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
on client: | |
ssh-keygen | |
ssh-copy-id username@remote_host | |
Disabling password authentication on server: | |
edit /etc/ssh/sshd_config | |
-> PasswordAuthentication no | |
service ssh restart | |
voilá |
This file contains 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 obj = { | |
init: function() { | |
console.log("init old"); | |
} | |
}; | |
var old_obj = {}; | |
_.extend(old_obj, obj); |
This file contains 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 currentMap = new Image(), | |
mrBrown = new Image(); | |
lastMap = new Image(); | |
currentMap.src = 'res/010/010-010.png'; | |
mrBrown.src = "res/mr_brown.gif"; | |
var canvas = document.createElement('canvas'); | |
canvas.width = 320; |
OlderNewer