Should submissions written in JS that return a promise be allowed?

For example:


Doesn't output "hi", but outputs a promise that resolves with the value of "hi". If you want "hi", then


is needed. Should the .then(console.log) part be required (and therefore part of the byte count)?

  • \$\begingroup\$ You might want to clarify what a promise is. \$\endgroup\$
    – Dennis
    May 10, 2017 at 17:26

1 Answer 1


No byte penalty

This is just an (abnormal) way of output that can show up often in fetch / submissions. I think this is absolutely fine.

  • \$\begingroup\$ In the future, please don't post answers for both sides. Let the people who actually support a side post an answer for it. Also, you don't need to make the answers community wiki. (you can, it's just not needed) \$\endgroup\$
    – Riker
    May 10, 2017 at 17:32