Question: Find and FIx the error } public class Examen{ float[] arrglo; float suma; int contNegativos; public Examen () { this.arrglo-new float [15]; this.suma=0; this.contNegativos=0; }
![} public class Examen{ float[] arrglo; float suma; int contNegativos; public Examen](https://dsd5zvtm8ll6.cloudfront.net/si.experts.images/questions/2024/01/65ba6b6808f8d_00765ba6b67d2bc3.jpg)
![() { this.arrglo-new float [15]; this.suma=0; this.contNegativos=0; } public void SetElemento (int](https://dsd5zvtm8ll6.cloudfront.net/si.experts.images/questions/2024/01/65ba6b6868b1d_00865ba6b684c6b9.jpg)
} public class Examen{ float[] arrglo; float suma; int contNegativos; public Examen () { this.arrglo-new float [15]; this.suma=0; this.contNegativos=0; } public void SetElemento (int pos, float valor) { if (pos 14) throw new IndexOutOfBoundsException("Invalid pos value!"); this.arrglo[pos]=valor; } public void calcular Suma () { for (int i=0;i
Step by Step Solution
There are 3 Steps involved in it
Solution Answer for the following question The error is resolved and below is the corrected code This problem will be having 2 files 1 Examenjava 2 Pruebajava Following Codes 1 Examenjava public class ... View full answer
Get step-by-step solutions from verified subject matter experts
