Help w/ input and output with JS

Help w/ input and output with JS
0.0 0


This is slightly unrelated because I’m currently doing a little algorithm course on Coursera, but I full-on confused.

To sumbit the assignment, we have to submit the code and if it works we pass, if it doens’t, obviously we fail. I’m super effing lost on how to do this. I have never interacted with code and the terminal at the same time this way and it’s apparently what they want but the instructions aren’t very clear at all about it.

I know how to do stuff in the terminal, and I obviously know how to code in JS, but I’m real confused on how to do this.

So anyway, you have to write a function that returns the sum of two different numbers. That part is fine. I got that. But you have to submit the code and then be able to somehow input numbers via the termninal (??? I think) to test it. I just don’t know how to do this at all. I’ve googled and what not but I can’t figure it out.

Pls halp.


like with prompt? or like actual console?


No, like, the CLI. But I actually figured it out thanks to this question on stackoverflow. :slight_smile: