Skip to content

Instantly share code, notes, and snippets.

View nirajkrz's full-sized avatar

ncode nirajkrz

View GitHub Profile
anonymous
anonymous / bonfire-roman-numeral-converter.js
Created December 3, 2015 02:29
http://www.freecodecamp.com/nirajkrz 's solution for Bonfire: Roman Numeral Converter
// Bonfire: Roman Numeral Converter
// Author: @nirajkrz
// Challenge: http://www.freecodecamp.com/challenges/bonfire-roman-numeral-converter
// Learn to Code at Free Code Camp (www.freecodecamp.com)
function convert(num) {
if (!+num)
return false;
var digits = String(+num).split(""),
key = ["","C","CC","CCC","CD","D","DC","DCC","DCCC","CM",
anonymous
anonymous / bonfire-seek-and-destroy.js
Created December 3, 2015 02:18
http://www.freecodecamp.com/nirajkrz 's solution for Bonfire: Seek and Destroy
// Bonfire: Seek and Destroy
// Author: @nirajkrz
// Challenge: http://www.freecodecamp.com/challenges/bonfire-seek-and-destroy
// Learn to Code at Free Code Camp (www.freecodecamp.com)
function destroyer(arr) {
// Remove all the values
var args = Array.prototype.slice.call(arguments);
args.splice(0,1);
return arr.filter(function(element) {