1

Code output should be:

515

30

However, when I add variables a, b, c my output is 51530. I've added a + b just to test it, and the output was 515. I just can't figure out how to return the c so that it won't combine with the 515.

function Init_sta() {
//Start by initializing an input function
var a = String(__input_stdin_array[__input_currentline].trim());
__input_currentline += 1;

var b = String(__input_stdin_array[__input_currentline].trim());
__input_currentline += 1;

var c = String(__input_stdin_array[__input_currentline].trim());
__input_currentline += 1;
//Next we are to take 3 String inputs a, b and c

//Lastly we must concatenate them and return it
return (a + b + c);
}
June7
  • 19,874
  • 8
  • 24
  • 34
Hannah
  • 5
  • 1
  • 4
  • 2
    Please share a [Minimal, Complete, and Verifiable example](https://stackoverflow.com/help/mcve) – Ele Feb 04 '18 at 00:38

0 Answers0