Skip to content

Instantly share code, notes, and snippets.

Arvind Kumar nullv01d

Block or report user

Report or block nullv01d

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View es6kata-40.js
// 40: iterator - one example usage. Build an iterable and use it with some built-in ES6 constructs.
// To do: make all tests pass, leave the assert lines unchanged!
// Consumable users:
// - `consumableUser` contains a consumable user,
// - `anyLeft` tells if there is any user left that can be consumed.
class ConsumableUsers {
constructor() {
this.users = ['Alice', 'Bob'];
}
@nullv01d
nullv01d / Gulpfile.js
Created Jul 29, 2016 — forked from Hendrixer/Gulpfile.js
Gulpfile with Livereload, Nodemon, and other features
View Gulpfile.js
var gulp = require('gulp'),
concat = require('gulp-concat'),
plumber = require('gulp-plumber'),
server = require('tiny-lr')(),
refresh = require('gulp-livereload'),
mocha = require('gulp-mocha'),
stylus = require('gulp-stylus'),
notify = require('gulp-notify'),
nodemon = require('gulp-nodemon'),
jshint = require('gulp-jshint'),
@nullv01d
nullv01d / inplace_merge_sort.py
Last active Oct 3, 2015 — forked from m00nlight/gist:a076d3995406ca92acd6
Python merge sort in place, so space complexity is O(1)
View inplace_merge_sort.py
import random
def merge_sort(xs):
"""Inplace merge sort of array without recursive. The basic idea
is to avoid the recursive call while using iterative solution.
The algorithm first merge chunk of length of 2, then merge chunks
of length 4, then 8, 16, .... , until 2^k where 2^k is large than
the length of the array
"""
You can’t perform that action at this time.