Js advice: you can make your code several times faster simply by adding two slashes in the beginning of the line