$ docker
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
| 1) https://leetcode.com/problems/two-sum/ | |
| sum([1, 2, 5, 3, 4], 9) -> [2, 4] | |
| find closest sum | |
| sum([1, 8, 5, 6, 4], 15) -> [1, 3] | |
| 2) rotateMatrix([ | |
| [1, 2], | |
| [3, 4] | |
| ]); | |
| Result |
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
| const handler = { | |
| get(target, propKey, receiver) { | |
| if (/^_[0-9]+$/.test(propKey)) { | |
| const result = []; | |
| const first = Number(receiver); | |
| const last = Number(propKey.slice(1)); | |
| for (let i=first; i<=last; i++) { | |
| result.push(i); | |
| } | |
| return result; |
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
| function makeFakeConsole(func){ | |
| return new Proxy({},{ | |
| get:function(target,name,receiver){ | |
| return function(){ | |
| //at some point if array.from gets implimented | |
| //func(name,Array.from(arguments)); | |
| func(name,Array.prototype.slice.call(arguments)); | |
| } | |
| } | |
| }); |
As configured in my dotfiles.
start new:
tmux
start new with session name:
NewerOlder

