Académique Documents
Professionnel Documents
Culture Documents
/**
*
* @author PM
*/
public class Ejercicio_funciones {
int[] numeros={1,2,3,4,5,6,7,8,9};
mostrarArreglo(numeros);
for(int i=0;i<numeros.length;i++){
System.out.print(numeros[i]);
int suma=0;
for(int i=0;i<numeros.length;i++){
suma+=numeros[i];
}
return suma;
}
}
-----------------------------------------------------------------------------------
------------------------------------
-----------------------------------------------------------------------------------
------------------------------------
package ejercicio1_funciones;
import java.util.Scanner;
public class Ejercicio1_funciones {
int N;
N=sc.nextInt();
mostrarMensaje(N);
for(int i=0;i<n;i++){
-----------------------------------------------------------------------------------
----------------------------------
-----------------------------------------------------------------------------------
----------------------------------
package ejercicio2_funciones;
import java.util.Scanner;
int x,y;
x=lectura.nextInt();
y=lectura.nextInt();
calMax(x,y);
}
static void calMax(int a, int b){//necesito entregarle los numeros del arreglo
int max=0;
if(a>b){
max=a;
}else{
max=b;
}
-----------------------------------------------------------------------------------
----------------------------------
package ejercicio3_funciones;
import java.util.Scanner;
int x,y,z;
x=leerNumero();
y=leerNumero();
z=leerNumero();
calMax(x,y,z);
}
int numero;
numero=lectura.nextInt();
return numero;
static void calMax(int a, int b, int c){//necesito entregarle los numeros del
arreglo
int max=0;
max=a;
max=b;
}else{
max=c;
}