¡Nuevo curso! ¡Todo programador debería aprender IA Generativa!
Prueba una lección gratuita0
Rearrange the code to find and print the smallest element of the array (n is the size of the array).
for(int x=1; x<n; x++) { } cout << small; small = arr[x]; if(arr[x] < small) int small = arr[0];
2 Respuestas
+ 3
int small = arr[0];
for(int x=1; x<n; x++) {
if(arr[x] < small)
small = arr[x];
}
cout << small;
0
thank youuuuuuuuuuuuuuuuuuuuuuuuuu :*