First answer should be easiest/simple. Either brute force or first thing that comes to mind
- Brute Force
- loops
- hashing
- sorting
- space vs time complexity trade offs
| var | |
| PARALLEL_CONNECTS = 10, | |
| http = require('http'), | |
| sys = require('sys'), | |
| connectionCount = 0, | |
| messageCount = 0; | |
| lastMessages = 0; | |
| function addClient() { |
| function keepTrying(otherArgs, promise) { | |
| promise = promise||new Promise(); | |
| // try doing the important thing | |
| if(success) { | |
| promise.resolve(result); | |
| } else { | |
| setTimeout(function() { | |
| keepTrying(otherArgs, promise); |
| var cluster = require('cluster'), | |
| app = require('./app'); | |
| var workers = {}, | |
| count = require('os').cpus().length; | |
| function spawn(){ | |
| var worker = cluster.fork(); | |
| workers[worker.pid] = worker; | |
| return worker; |
| # Usage: redis-cli publish message.achannel hello | |
| require 'sinatra' | |
| require 'redis' | |
| conns = Hash.new {|h, k| h[k] = [] } | |
| Thread.abort_on_exception = true | |
| get '/' do |
| function UndoItem (perform, data) { | |
| this.perform = perform; | |
| this.data = data; | |
| } | |
| /** | |
| * UndoStack: | |
| * Easy undo-redo in JavaScript. | |
| **/ |
| /** | |
| * Basic Standard Filters for strings: | |
| * | |
| * {{size "Plus"}} | |
| * | |
| * Would give you 4! | |
| * | |
| * @author: Nijiko Yonskai | |
| */ | |
| var strings = { |
Attention: the list was moved to
https://github.com/dypsilon/frontend-dev-bookmarks
This page is not maintained anymore, please update your bookmarks.