title: Whenever I try run code it says runtime error.How can I fix it.(Hackerrank)
body: <p>I am new to here and Hackerrank.I am trying to solve simple array sum problem:</p>
  
  <pre><code>Given an array of integers, find the sum of its elements.
  
  For example, if the array , , so return .
  
  Function Description
  
  Complete the simpleArraySum function in the editor below. It must return the sum of the array elements as an integer.
  
  simpleArraySum has the following parameter(s):
  
  ar: an array of integers
  Input Format
  
  The first line contains an integer, , denoting the size of the array.
  The second line contains  space-separated integers representing the array's elements.
  
  Constraints
  
  
  Output Format
  
  Print the sum of the array's elements as a single integer.
  </code></pre>
  
  <p>I am trying to find solution but I couldn't find the solution so far.It works on jupyter notebook.It says:</p>
  
  <pre><code>Traceback (most recent call last):
    File "Solution.py", line 34, in &lt;module&gt;
      result = simpleArraySum(ar)
    File "Solution.py", line 13, in simpleArraySum
      amount=int(input())
  EOFError: EOF when reading a line
  </code></pre>
  
  <p>On output button it says 'no response on stdout'.Here is my code:</p>
  
  <pre><code>def simpleArraySum(ar):
      #
      # Write your code here.
      #
      amount=int(input())
  
      nums=list(map(int,input().split()))
  
      sums=0
  
      for i in nums:
  
          sums+=i
  
      print(sums)
  </code></pre>