Skip to content

Instantly share code, notes, and snippets.

View web20opensource's full-sized avatar
🎯
Focusing

Mario Ruiz web20opensource

🎯
Focusing
View GitHub Profile
@victordf
victordf / desafio.php
Created April 10, 2015 21:01
Desafio Folha
$g = array(
'halley' => 'amarelo',
'encke' => 'vermelho',
'wolf' => 'preto',
'kushida' => 'azul'
);
$l = array(
'a' => 1,
'z' => 26
@web20opensource
web20opensource / ex12
Last active August 29, 2015 14:19
Learning RxJs
return movieLists.map(
// map receives 3 args
// cat - element to iterate
// cIndex - index in the array of the element
// cCollection - movieLists array
// same applies for the rest if the code
(cat, cIndex, cCollection) => {
//v for videos object
return cat.videos.map ( (v,vIndex,vCollection) => {
@staltz
staltz / gist:78140b885f366886d9b5
Last active August 29, 2015 14:19
Terse Cycle.js

Terse Cycle.js

Take Cycle's primal example, on the README:

import Cycle from 'cyclejs';
let {Rx, h} = Cycle;

let name$ = Cycle.createStream(function model(changeName$) {
@mike-north
mike-north / setup.md
Last active October 8, 2015 15:08
frontendmasters.com - Ember 2.0 workshop - project setup

Front End Masters Ember.js Workshop - Setup

Windows + OS X

Make sure you have node.js installed.

You can verify that you have node.js by running node -v and you should see something like v0.12.7

Install ember-cli

@warecrash
warecrash / makekali.sh
Last active September 22, 2025 21:34
Convert Debian to Kali
apt update
apt -y install wget gnupg dirmngr
wget -q -O - https://archive.kali.org/archive-key.asc | gpg --import
gpg --keyserver hkp://keys.gnupg.net --recv-key 44C6513A8E4FB3D30875F758ED444FF07D8D0BF6
echo "deb http://http.kali.org/kali kali-rolling main non-free contrib" >> /etc/apt/sources.list
gpg -a --export ED444FF07D8D0BF6 | sudo apt-key add -
apt update
apt -y upgrade
apt -y dist-upgrade
apt -y autoremove --purge
@getify
getify / 1.js
Last active September 6, 2024 19:05
Converting English number sentences ("one hundred forty two point three") to numeric digits ("142.3")
convert("one hundred five"); // "105"
convert("six hundred and fifty three"); // "653"
convert("zero zero one two three"); // "123"
convert("twelve o three"); // "1203"
convert("thirteen zero nine"); // "1309"
convert("fifteen sixteen"); // "1516"
convert("fourteen ninety two"); // "1492"
convert("nineteen ten"); // "1910"
convert("twelve hundred"); // "1200"
convert("twenty three hundred"); // "2300"