Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Clear category for [old] House Password by Sim0000
"use strict";
function housePassword(data){
if(data.length < 10) return false;
if(data.search(/[A-Z]/g) < 0) return false;
if(data.search(/[a-z]/g) < 0) return false;
if(data.search(/[0-9]/g) < 0) return false;
return true;
}
var assert = require('assert');
if (!global.is_checking) {
assert.equal(housePassword("A1213pokl"), false, "1st example");
assert.equal(housePassword("bAse730onE4"), true, "2nd example");
assert.equal(housePassword("asasasasasasasaas"), false, "3rd example");
assert.equal(housePassword("QWERTYqwerty"), false, "4th example");
assert.equal(housePassword("123456123456"), false, "5th example");
assert.equal(housePassword("QwErTy911poqqqq"), true, "6th example");
}
May 15, 2017
Comments: