add solution 2 with nodejs