+ 1
I was creating a program to find largest and smallest number from array
I was creating a program to find largest and smallest number from array but there is error in program ,help me solve the error link of code: https://code.sololearn.com/c5n3bR2YAE32/?ref=app
2 ответов
+ 3
You have to change the line 17 on:
L = S = n[0];
+ 2
Abhishek Shelar
You have to store first value in a temp variable
If you want to store last value in a temp variable then you need to do (i - 1) because index start from 0 so last index would be (i - 1)