More Related Content
More from Jhair Aguirre (11)
Ejercicios jimena
- 1. Ejercicios
1) package ejercicio2;
import java.io.*;
public classEjercicio2 {
public static void main(String[] args)throws IOException{
int v,a,s,o;
floatvaso;
BufferedReader in =new BufferedReader(new InputStreamReader(System.in));
System.out.println("ingresa v,a,s,o");
v=Integer.parseInt(in.readLine());
a=Integer.parseInt(in.readLine());
s=Integer.parseInt(in.readLine());
o=Integer.parseInt(in.readLine());
vaso=v+a+s+o;
System.out.println("vaso"+vaso);
}
}
2).
packageejercicio3;
import java.io.*;
public classEjercicio3 {
public static void main(String[] args)throws IOException{
int c,a,n,t,o;
floatcanto;
BufferedReader in =new BufferedReader(new InputStreamReader(System.in));
System.out.println("ingresa c,a,n,t,o");
c=Integer.parseInt(in.readLine());
a=Integer.parseInt(in.readLine());
n=Integer.parseInt(in.readLine());
t=Integer.parseInt(in.readLine());
o=Integer.parseInt(in.readLine());
canto= c+a+n+t+o;
System.out.println("canto"+canto);
}
}
3).
packageejercicio4;
import java.io.*;
public classEjercicio4 {
public static void main(String[] args)throws IOException {
int f,l,o,r;
floatflor;
BufferedReader in =new BufferedReader(new InputStreamReader(System.in));
System.out.println("ingresa f,l,o,r");
f=Integer.parseInt(in.readLine());
l=Integer.parseInt(in.readLine());
o=Integer.parseInt(in.readLine());
r=Integer.parseInt(in.readLine());
flor= f+l+o+r;
- 2. System.out.println("flor"+flor);
}
}
4).
packageejercicio5;
import java.io.*;
public classEjercicio5 {
public static void main(String[] args)throws IOException {
int s,a,l;
floatsal;
BufferedReader in =new BufferedReader(new InputStreamReader(System.in));
System.out.println("ingresa s,a,l");
s=Integer.parseInt(in.readLine());
a=Integer.parseInt(in.readLine());
l=Integer.parseInt(in.readLine());
sal=s+a+l;
System.out.println("sal"+sal);
}
}
5).
packageejercicio6;
import java.io.*;
public classEjercicio6 {
public static void main(String[] args) throws IOException {
int u,n,o;
floatuno;
BufferedReader in =new BufferedReader(new InputStreamReader(System.in));
System.out.println("ingresa u,n,o");
u=Integer.parseInt(in.readLine());
n=Integer.parseInt(in.readLine());
o=Integer.parseInt(in.readLine());
uno= u+n+o;
System.out.println("uno"+uno);
}
}
6).
packageejercicio7;
import java.io.*;
public classEjercicio7 {
public static void main(String[] args)throws IOException {
int t,e,c,l,a;
floattecla;
BufferedReader in =new BufferedReader(new InputStreamReader(System.in));
System.out.println("ingresa t,e,c,l,a");
t=Integer.parseInt(in.readLine());
e=Integer.parseInt(in.readLine());