Attention: the list was moved to
https://github.com/dypsilon/frontend-dev-bookmarks
This page is not maintained anymore, please update your bookmarks.
#!/bin/bash | |
java_binary_link="/usr/bin/java" | |
java_library="libjvm.so" | |
library_paths=( | |
/jre/lib/amd64/server | |
/jre/lib/amd64/client | |
/usr/lib | |
/lib |
Attention: the list was moved to
https://github.com/dypsilon/frontend-dev-bookmarks
This page is not maintained anymore, please update your bookmarks.
# to generate your dhparam.pem file, run in the terminal | |
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048 |
package slick | |
/** | |
* This is some code extracted from TimeOut codebase, demonstrating: | |
* - Use of tag typed to avoid mixing session of different DB | |
* - The use of the Reader Monad to compose Actions together and defer the choice of async/sync computation | |
* | |
* I remove the part where we can say if our operation are read only or not (to use different connection), in order to | |
* make things easier. | |
**/ |
// based on http://msdn.microsoft.com/en-us/magazine/hh335067.aspx | |
// usage example at bottom | |
function pso (number_of_dimensions, function_to_optimize, number_of_particles, number_of_iterations, fitness_threshold, inertia_weight, cognitive_weight, social_weight) { | |
var particles = []; | |
var swarm_best_position = []; | |
var swarm_best_fitness = null; | |
for (var p = 0; p < number_of_particles; p++) { | |
particles.push({ | |
particle_position: [], |