- 4

Can you help me?

Write a function that find the sum of positive elements in the array that are located in front of the maximum element. Note. The program have to use pointer. Input: First line contains n (1<=n<=100) Than n numbers are inputed. Output: The sum of elements before maximum. Samples: № Input 1 8 9 1 -1 -1 9 1 1 0 Output 10

16th Oct 2020, 1:14 PM
Nurlan
Nurlan - avatar
3 ответов
+ 6
Nurlan don't u understand... There's no machine here to code for u.. Try code yourself , if ur stuck or gets an error. We will be happy to help..
16th Oct 2020, 1:18 PM
Alphin K Sajan
Alphin K Sajan - avatar
+ 3
Nurlan You have a classmate here asking the same topic. But he gave the task a shot. https://www.sololearn.com/Discuss/2547318/?ref=app
16th Oct 2020, 1:37 PM
Ipang
16th Oct 2020, 4:13 PM
The future is now thanks to science
The future is now thanks to science - avatar