not using c++; javascript