Skip to content

Instantly share code, notes, and snippets.

View faiwer's full-sized avatar

Stepan Zubashev faiwer

View GitHub Profile
const kittens = [];
for(const cat of cats)
{
if(cat.months < 7)
{
kittens.push(cat.name);
if(kittens.length === limit)
break;
}
}
#!/bin/bash
### BEGIN INIT INFO
# Provides: %name%
# Required-Start: $network $remote_fs $local_fs
# Required-Stop: $network $remote_fs $local_fs
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: forever-service startup script for %name%
# Description: forever-service startup script for node script based service %name%, uses forever to start the service
const { Suite } = require("benchmark");
const Random = require("random-js");
const { map, into, compose, filter, take, pluck } = require("ramda");
const suite = new Suite();
const random = new Random();
function present({ name, hz, count }) {
console.log(
`
the = 4144
and = 2193
to = 2042
a = 1812
of = 1656
harry = 1516
he = 1402
was = 1266
said = 1218
his = 1169
(function()
{
"use strict";
let limit = 100000;
class A1
{
a1(){ return '1'; }
b1(){ return 1; }
(function()
{
"use strict";
function test(label, co)
{
let times = 3000;
function * g1(){ return 1; }
function * g2()
{
Traceback (most recent call last):
File "/home/faiwer/po/sublime_text_3/sublime_plugin.py", line 524, in run_
return self.run(**args)
TypeError: run() got an unexpected keyword argument 'regex_exclude'
reloading plugin FuzzyFileNav.fuzzy_file_nav
Traceback (most recent call last):
File "/home/faiwer/po/sublime_text_3/sublime_plugin.py", line 71, in reload_plugin
m = imp.reload(m)
File "./imp.py", line 276, in reload
File "<frozen importlib._bootstrap>", line 584, in _check_name_wrapper
File "<frozen importlib._bootstrap>", line 1022, in load_module
File "<frozen importlib._bootstrap>", line 1003, in load_module
File "<frozen importlib._bootstrap>", line 560, in module_for_loader_wrapper
File "<frozen importlib._bootstrap>", line 853, in _load_module