Given a list of integers , and a string of length and with characters ’+’ and ’-’, we need to print the result of summing or subtracting each depending on whether the ’th character of is ’+’ or ’-’.
The input begins with a positive natural number on a first line. On a second line there are integers . Afterwards, there’s a sequence of lines, each with a string of length and characters ’+’ or ’-’.
For each string , the program has to print
Author: PRO1
Generation: 2026-01-25T15:18:25.246Z
© Jutge.org, 2006–2026.
https://jutge.org