SlideShare a Scribd company logo
1 of 21
ejercicio 01
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package porpuesto009;
import java.io.*;
import java.util.Scanner;
/**
*
* @author gaviota
*/
public class Porpuesto009 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
Scanner ap = new Scanner (System.in);
double a, b ,c;
System.out.println("Área y perímetro de un Rectagulo");
System.out.println("Ingrese el valor de a");
a= ap.nextInt();
System.out.println("ingrese el valor de b");
b= ap.nextInt();
double area= a*b;
double perimetro=2*a+2*b;
System.out.println("El Área de un rectångulo es = " + area);
System.out.println("El PerĂ­metro de un rectĂĄngulo es = " + perimetro);
}
}
ejercicio 02
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema.nÂș2;
import java.io.*;
/**
*
* @author sujei
*/
public class ProblemaNÂș2 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
int n1,n2,s;
BufferedReader in =new BufferedReader(new
InputStreamReader(System.in));
System.out.println("numero 1:");
n1 = Integer.parseInt(in.readLine());
System.out.println("numero 2:");
n2 = Integer.parseInt(in.readLine());
s=n1+n2;
System.out.println("");
System.out.println("suma: " +s);
}
}
ejercicio 03
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema3;
import java.io.*;
/**
*
* @author sujei
*/
public class Problema3 {
/**
* @param args the command line arguments
*/
public static void main(String[] args)throws IOException {
//varible
int n1,n2,c,r;
BufferedReader in =new BufferedReader(new
InputStreamReader(System.in));
System.out.println("numero 1:");
n1 = Integer.parseInt(in.readLine());
System.out.println("numero 2:");
n2 = Integer.parseInt(in.readLine());
//proceso
c=n1/n2;
r=n1%n2;
//salida
System.out.println("");
System.out.println("cociente: " +c);
System.out.println("residuo: " +r);
// TODO code application logic here
}}
ejercio 04
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema.pkg4;
import java.io.*;
/**
*
* @author sujei
*/
public class Problema4 {
/**
* @param args the command line arguments
*/
public static void main(String[] args)throws IOException {
//variable
float vv,igv,pv;
//entrada
BufferedReader in =new BufferedReader(new
InputStreamReader(System.in));
System.out.println("valor de venta:");
vv =Float.parseFloat(in.readLine());
//proceso
igv = vv *0.18f;
pv = vv+ igv;
//salida
System.out.println("");
System.out.println("igv: " +igv);
System.out.println("precio de venta: " +pv);
// TODO code application logic here
}
}
Ejercicio 5
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema004;
import java.io.*;
/**
*
* @author sujei
*/
public class Problema004 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
short a,n;
int p;
BufferedReader in =new BufferedReader(new
InputStreamReader(System.in));
System.out.println("a: ");
a=Short.parseShort(in.readLine());
System.out.println("n: ");
n=Short.parseShort(in.readLine());
// TODO code application logic here
p=(int)Math.pow((double)a, (double)n);
System.out.println("");
System.out.println("Potencia: "+p);
}
}
Ejercio 4
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema04;
/**
*
* @author sujei
*/
public class Problema04 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
// TODO code application logic here
}
}
Ejercicio5
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema05;
import java.io.*;
/**
*
* @author sujei
*/
public class PROBLEMA05 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
short n,r;
int a;
BufferedReader in =new BufferedReader(new
InputStreamReader(System.in));
System.out.println("a: ");
a=Integer.parseInt(in.readLine());
System.out.println("n: ");
n=Short.parseShort(in.readLine());
// TODO code application logic here
r=(short)Math.pow((double)a, (1/(double)n));
System.out.println("");
System.out.println("RadicaciĂłn: "+r);
// TODO code application logic here
}
}
Ejercio 6
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema06;
import java.io.*;
/**
*
* @author sujei
*/
public class PROBLEMA06 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
// TODO code application logic here
int n, ni, r;
BufferedReader in =new BufferedReader(new
InputStreamReader(System.in));
System.out.println("NĂșmero: ");
n=Integer.parseInt(in.readLine());
r=n%10;
n=n/10;
ni=r*10;
r=n%10;
n=n/10;
ni=(ni+r)*10;
r=n%10;
n=n/10;
ni=(ni+r)*10;
r=n%10;
n=n/10;
ni=(ni+r)*10;
ni=ni+n;
System.out.println("");
System.out.println("Inverso: " + ni);
}
}
Ejercicio7
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema07;
import java.io.*;
/**
*
* @author sujei
*/
public class PROBLEMA07 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
// TODO code application logic here
int n,s;
BufferedReader in =new BufferedReader(new
InputStreamReader(System.in));
System.out.println("NĂșmero: ");
n=Integer.parseInt(in.readLine());
s=(n*(n+1))/2;
System.out.println("");
System.out.println("Suma: " + s);
}
}ejercicio 8
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema8;
import java.io.*;
/**
*
* @author sujei
*/
public class Problema8 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
float c, r, t, i, m;
BufferedReader in =new BufferedReader(new
InputStreamReader(System.in));
System.out.println("Capital: ");
c=Float.parseFloat(in.readLine());
System.out.println("Tasa de interes: ");
r=Float.parseFloat(in.readLine());
System.out.println("Tiempo: ");
t=Float.parseFloat(in.readLine());
m=(float)(Math.pow((double)(1+r/100),(double)t))*c;
i=m-c;
System.out.println("");
System.out.println("Interes: " + i);
System.out.println("Monto: " + m);
}
}
Ejercicio10
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema10;
import java.io.*;
/**
*
* @author sujei
*/
public class Problema10 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
final int HORA=3600;
final int MINUTO=60;
int t,h,m,s;
BufferedReader in =new BufferedReader(new InputStreamReader(System.in));
System.out.println("Tiempo en segundos: ");
t=Integer.parseInt(in.readLine());
h=t/HORA;
//t=t%HORA;
m=t/MINUTO;
s=t;
System.out.println("");
System.out.println("Horas: "+h);
System.out.println("Minutos: "+m);
System.out.println("Segundos: "+s);
// TODO code application logic here
}
}
Ejercicio11
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema11;
import java.io.*;
/**
*
* @author sujei
*/
public class Problema11 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
int a,b,n1,n2;
BufferedReader in =new BufferedReader(new
InputStreamReader(System.in));
System.out.println("NĂșmero1: ");
a=Integer.parseInt(in.readLine());
System.out.println("NĂșmero2: ");
b=Integer.parseInt(in.readLine());
n1=a+b;
n2=a-b;
System.out.println("");
System.out.println("Suma: " + n1);
System.out.println("Resta: " + n2);
// TODO code application logic here
}
}
Ejercicio 12
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema12;
import java.io.*;
/**
*
* @author sujei
*/
public class Problema12 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
int a,b;
BufferedReader in =new BufferedReader(new
InputStreamReader(System.in));
a=Integer.parseInt(in.readLine());
b=Integer.parseInt(in.readLine());
String x = Integer.toString(a);
String y = Integer.toString(b);
System.out.println("el 1er nĂșmero ingresado tiene: " + x.length() +
" dĂ­gitos");
System.out.println("el 2do nĂșmero ingresado tiene: " + y.length() +
" dĂ­gitos");
// TODO co de application logic here
}
}
ejecicio
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema012;
import java.io.*;
/**
*
* @author sujei
*/
public class Problema012 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException{
int n;
String r = "";
BufferedReader in=new BufferedReader(new InputStreamReader(System.in));
System.out.println("NĂșmero: ");
n=(int)Integer.parseInt(in.readLine());
if (n>0)
ejercicio13
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema013;
import java.util.Scanner;
/**
*
* @author sujei
*/
public class Problema013 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
char c;
//String r="";
System.out.println("Caracter");
Scanner teclado=new Scanner(System.in);
c=teclado.next().charAt(0);
if(c=='a'||c=='e'||c=='i'||c=='o'||c=='u'||c=='A'||c=='E'||c=='I'||c=='O'
||c=='U'){
//r="es vocal";}
System.out.println("ES VOCAL");
} else{
//r="no es vocal"; }
System.out.println("NO ES VOCAL");
}//System.out.println("la letra ingresada "+r);
}
}
{
r="POSITIVO";
}
if (n<0)
{
r="NEGATIVO";
}
if(n==0)
{
r="NEUTRO";
}
System.out.println("");
System.out.println("Resultado: "+r);
}
}
ejercicio
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema13;
import java.io.*;
/**
*
* @author sujei
*/
public class Problema13 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
final int METRO=1000;
final int DECIMETRO=100;
final int CENTIMETRO=10;
int mm,m,d,c;
BufferedReader in =new BufferedReader(new InputStreamReader(System.in));
System.out.println("Cantidad de milĂ­metros: ");
mm=Integer.parseInt(in.readLine());
m=mm/METRO;
d=mm/DECIMETRO;
c=mm/CENTIMETRO;
System.out.println("");
System.out.println("Metros: "+m);
System.out.println("DecĂ­metros: "+d);
System.out.println("CentĂ­metros: "+c);
System.out.println("MilĂ­metros: "+mm);
// TODO code application logic here
}
}
Ejercicio 14
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema14;
import java.io.*;
/**
*
* @author gaviota
*/
public class PROBLEMA14 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
double a, b, c, d, e;
BufferedReader in =new BufferedReader(new InputStreamReader(System.in));
System.out.println("Ingresa un nĂșmero, serĂĄ el valor de a ");
a=Integer.parseInt(in.readLine());
System.out.println("Ingresa un nĂșmero, serĂĄ el valor de b ");
b=Integer.parseInt(in.readLine());
System.out.println("Ingresa un nĂșmero, serĂĄ el valor de c ");
c=Integer.parseInt(in.readLine());
d=(4*(a*a*a*a)+(3*b*a)+(b*b))/(a*a-b*b);
e=((3*(c*c))+a+b)/4;
System.out.println("");
System.out.println("El resultado de la fĂłrmula siguiente
c=(4*a^4+3*b*a+b^2)/a^2-b^2, es: "+d);
System.out.println("El resultado de la fĂłrmula siguiente
d=(3*c^2+a+b)/4, es: "+e);
// TODO code application logic here
}
}
Ejercicio15
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema015;
import java.io.*;
/**
*
* @author sujei
*/
public class PROBLEMA015 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException{
// TODO code application logic here
int n;
String r;
BufferedReader in=new BufferedReader(new InputStreamReader(System.in));
System.out.println("NĂșmero: ");
n=Integer.parseInt(in.readLine());
if(n%2==0)
{
r= "PAR";
}
else
{
r= "IMPAR";
}
System.out.println("");
System.out.println("Resultado: " + r);
System.out.println();
}
}
ejercicio
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema15;
import java.io.*;
/**
*
* @author sujei
*/
public class Problema15 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
int a=1, b=2, c=3, d=4;
int s=a+b+c+d;
double porcentaje_a=(double)(a*100)/s;
double porcentaje_b=(double)(b*100)/s;
double porcentaje_c=(double)(c*100)/s;
double porcentaje_d=(double)(d*100)/s;
System.out.println("");
System.out.println("La variable "a" representa el: "+porcentaje_a+"%
de "+s);
System.out.println("La variable "b" representa el: "+porcentaje_b+"%
de "+s);
System.out.println("La variable "c" representa el: "+porcentaje_c+"%
de "+s);
System.out.println("La variable "d" representa el: "+porcentaje_d+"%
de "+s);
// TODO code application logic here
}
}
Ejercicio 16
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema016;
import java.io.*;
/**
*
* @author sujei
*/
public class PROBLEMA016 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException{
int n1,n2,n3,m;
BufferedReader in=new BufferedReader(new InputStreamReader(System.in));
System.out.println("NĂșmero 1: ");
n1= Integer.parseInt(in.readLine());
System.out.println("NĂșmero 2: ");
n2=Integer.parseInt(in.readLine());
System.out.println("NĂșmero 3: ");
n3= Integer.parseInt(in.readLine());
if (n1>n2)
{
if(n1>n3)
{
m=n1;
}
else
{
m=n3;
}
}
else
{
if(n2>n3)
{
m=n2;
}
else
{
m=n3;
}
}
System.out.println("");
System.out.println("Mayor: " +m);
}
}
Ejercicio17
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema017;
import java.io.*;
/**
*
* @author sujei
*/
public class PROBLEMA017 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException{
int n,r;
BufferedReader in=new BufferedReader(new InputStreamReader(System.in));
System.out.println("NĂșmero: ");
n = Integer.parseInt(in.readLine());
if (!(n%2==0))
{
r=n*2;
}
else
{
r=n*3;
}
System.out.println("");
System.out.println("Resultado: " + r);
System.out.println();
}
}
Ejercicio18
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema18;
import java.io.*;
/**
*
* @author sujei
*/
public class Problema18 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
double f,k,c;
BufferedReader in =new BufferedReader(new InputStreamReader(System.in));
System.out.println("Grados Fahrenheit: ");
f=Integer.parseInt(in.readLine());
c = (f-32)/1.8;
k = (f-32)*5/9+273.15;
System.out.println("");
System.out.println("A grados Celsius: "+c);
System.out.println("A grados Kelvin: "+k);
}
}
dReader(new InputStreamReader(System.in));
System.out.println("Grados Sexagesimales: ");
s=Integer.parseInt(in.readLine());
c=s*200/180;
System.out.println("");
System.out.println("A grados Centesimales: "+c);
}
}
Ejercicio 19
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema019;
import java.io.*;
/**
*
* @author sujei
*/
public class Problema019 {
/**
* @param args the command line arguments
*/
public static void main(String[] args)throws IOException{
final float D1=0.1F;
final float D2=0.2F;
final float IGV=0.18F;
float c,m_d, m_igv, p;
BufferedReader in=new BufferedReader(new InputStreamReader(System.in));
System.out.println("Consumo: ");
c=(float)Integer.parseInt(in.readLine());
if(c<=100)
{
m_d=c * D1;
}
else
{
m_d=c * D2;
}
m_igv=(c-m_d) * IGV;
p= c - m_d + m_igv;
System.out.println("");
System.out.println("Monto descuento: " + m_d);
System.out.println("Impuesto IGV: " + m_igv);
System.out.println("Importe a pagar: " + p);
System.out.println();
}
}
Ejercicio20
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema20;
import java.io.*;
/**
*
* @author sujei
*/
public class Problema20 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
double s,c;
BufferedReader in =new BufferedReader(new InputStreamReader(System.in));
System.out.println("Grados Sexagesimales: ");
s=Integer.parseInt(in.readLine());
c=s*200/180;
System.out.println("");
System.out.println("A grados Centesimales: "+c);
}
}
EJERCICIO21
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema21;
import java.io.*;
/**
*
* @author CARLITA
*/
public class Problema21 {
/**
* @param args the command line arguments
*/
public static void main(String[] args)throws IOException {
double s;
BufferedReader in =new BufferedReader(new
InputStreamReader(System.in));
System.out.println("incendiohohoohho");
EJERCICIO22
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema022;
import java.util.Scanner;
/**
*
* @author SUJEI
*/
public class Problema022 {
/**
* @param args the command line arguments
*/
public static void main(String[] args){
Scanner in =new Scanner(System.in);
final float DESC_G = 0.15F;
final float DESC_A = 0.2F;
final float REC_G = 0.1F;
final float REC_A = 0.05F;
//variables
float mc, m, tp;
//char tc,fp;
String r ;
String tc;
String fp;
System.out.println("Monto de compra: ");
mc=in.nextFloat();
System.out.println("Tipo de cliente: ");
tc =in.next();
System.out.println("Forma de pago: ");
fp=in.next();
if(tc=="G")
{
if(fp=="C")
{
m = mc * DESC_G;
tp = mc - m;
r = "DESCUENTO 15%";
}
else
{
m = mc * REC_G;
tp = mc + m;
r = "RECARGO 10%";
}
}
else
{
if (fp=="C")
{
m = mc * DESC_A;
tp = mc - m;
ejercicio23
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema023;
import java.io.*;
/**
*
* @author sujei
*/
public class PROBLEMA023 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException{
float a,b,x;
BufferedReader in=new BufferedReader(new InputStreamReader(System.in));
System.out.println("a: ");
a=Float.parseFloat(in.readLine());
System.out.println("b: ");
b=Float.parseFloat(in.readLine());
if(a!=0)
{
x=-b/a;
}
else
{
x=0;
}
System.out.println("");
System.out.println("x: " + x);
System.out.println();
}
}
Ejercicio24
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema024;
import java.io.*;
/**
*
* @author sujei
*/
public class Problema024 {
/**
* @param args the command line arguments
*/
public static void main(String[] args)throws IOException {
double a,b,c,d,x1,x2;
BufferedReader in=new BufferedReader(new InputStreamReader(System.in));
System.out.println("a: ");
a=(double) Integer.parseInt(in.readLine());
System.out.println("b: ");
b=(double)Integer.parseInt(in.readLine());
System.out.println("c: ");
c=(double) Integer.parseInt(in.readLine());
d = Math.pow(b,2)-4*c;
if(a!=0 && d>=0)
{
x1 = (-b+Math.pow(d,(1.0/2)))/2*a;
x2 = (-b-Math.pow(d,(1.0/2)))/2*a;
}
else
{
x1 = 0;
x2 = 0;
}
System.out.println("");
System.out.println("x1: " + x1);
System.out.println("x2: " + x2);
System.out.println();
}
}
Ejercicio25
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package problema0025;
import java.io.*;
/**
*
* @author sujei
*/
public class Problema0025 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws IOException {
int h,m,s;
BufferedReader in=new BufferedReader(new InputStreamReader(System.in));
System.out.println("Hora: ");
h= Integer.parseInt(in.readLine());
System.out.println("Minuto: ");
m=Integer.parseInt(in.readLine());
System.out.println("Segundo: ");
s= Integer.parseInt(in.readLine());
s+=1;
if (s==60)
{
s=0;
m+=1;
if(m==60)
{
m=0;
h+=1;
if(h==24)
{
h=0;
}
}
}
System.out.println("");
System.out.println("Hora: " + h);
System.out.println("Minuto: " + m);
System.out.println("Segundo: " + s);
System.out.println();
}
}

More Related Content

What's hot

Checking Intel IPP Samples for Windows - Continuation
Checking Intel IPP Samples for Windows - ContinuationChecking Intel IPP Samples for Windows - Continuation
Checking Intel IPP Samples for Windows - ContinuationPVS-Studio
 
ĐšĐŸĐČĐ°Ń€ĐœŃ‹ĐžÌ† code type ITGM #9
ĐšĐŸĐČĐ°Ń€ĐœŃ‹ĐžÌ† code type ITGM #9ĐšĐŸĐČĐ°Ń€ĐœŃ‹ĐžÌ† code type ITGM #9
ĐšĐŸĐČĐ°Ń€ĐœŃ‹ĐžÌ† code type ITGM #9Andrey Zakharevich
 
Java Generics - by Example
Java Generics - by ExampleJava Generics - by Example
Java Generics - by ExampleGanesh Samarthyam
 
Rechecking SharpDevelop: Any New Bugs?
Rechecking SharpDevelop: Any New Bugs?Rechecking SharpDevelop: Any New Bugs?
Rechecking SharpDevelop: Any New Bugs?PVS-Studio
 
Base de-datos
Base de-datosBase de-datos
Base de-datosferney1428
 
Use of Apache Commons and Utilities
Use of Apache Commons and UtilitiesUse of Apache Commons and Utilities
Use of Apache Commons and UtilitiesPramod Kumar
 
ITGM #9 - ĐšĐŸĐČĐ°Ń€ĐœŃ‹Đč CodeType, ОлО ĐŸŃ‚ segfault'Đ° Đș Ń€Đ°Đ±ĐŸŃ‚Đ°ŃŽŃ‰Đ”ĐŒŃƒ ĐșĐŸĐŽŃƒ
ITGM #9 - ĐšĐŸĐČĐ°Ń€ĐœŃ‹Đč CodeType, ОлО ĐŸŃ‚ segfault'Đ° Đș Ń€Đ°Đ±ĐŸŃ‚Đ°ŃŽŃ‰Đ”ĐŒŃƒ ĐșĐŸĐŽŃƒITGM #9 - ĐšĐŸĐČĐ°Ń€ĐœŃ‹Đč CodeType, ОлО ĐŸŃ‚ segfault'Đ° Đș Ń€Đ°Đ±ĐŸŃ‚Đ°ŃŽŃ‰Đ”ĐŒŃƒ ĐșĐŸĐŽŃƒ
ITGM #9 - ĐšĐŸĐČĐ°Ń€ĐœŃ‹Đč CodeType, ОлО ĐŸŃ‚ segfault'Đ° Đș Ń€Đ°Đ±ĐŸŃ‚Đ°ŃŽŃ‰Đ”ĐŒŃƒ ĐșĐŸĐŽŃƒdelimitry
 
Picking Mushrooms after Cppcheck
Picking Mushrooms after CppcheckPicking Mushrooms after Cppcheck
Picking Mushrooms after CppcheckAndrey Karpov
 
JPC#8 Introduction to Java Programming
JPC#8 Introduction to Java ProgrammingJPC#8 Introduction to Java Programming
JPC#8 Introduction to Java ProgrammingPathomchon Sriwilairit
 
E:\Plp 2009 2\Plp 9
E:\Plp 2009 2\Plp 9E:\Plp 2009 2\Plp 9
E:\Plp 2009 2\Plp 9Ismar Silveira
 
Java Simple Programs
Java Simple ProgramsJava Simple Programs
Java Simple ProgramsUpender Upr
 
Introduzione al TDD
Introduzione al TDDIntroduzione al TDD
Introduzione al TDDAndrea Francia
 

What's hot (16)

Java programs
Java programsJava programs
Java programs
 
Checking Intel IPP Samples for Windows - Continuation
Checking Intel IPP Samples for Windows - ContinuationChecking Intel IPP Samples for Windows - Continuation
Checking Intel IPP Samples for Windows - Continuation
 
ĐšĐŸĐČĐ°Ń€ĐœŃ‹ĐžÌ† code type ITGM #9
ĐšĐŸĐČĐ°Ń€ĐœŃ‹ĐžÌ† code type ITGM #9ĐšĐŸĐČĐ°Ń€ĐœŃ‹ĐžÌ† code type ITGM #9
ĐšĐŸĐČĐ°Ń€ĐœŃ‹ĐžÌ† code type ITGM #9
 
Java Generics - by Example
Java Generics - by ExampleJava Generics - by Example
Java Generics - by Example
 
Rechecking SharpDevelop: Any New Bugs?
Rechecking SharpDevelop: Any New Bugs?Rechecking SharpDevelop: Any New Bugs?
Rechecking SharpDevelop: Any New Bugs?
 
Base de-datos
Base de-datosBase de-datos
Base de-datos
 
Use of Apache Commons and Utilities
Use of Apache Commons and UtilitiesUse of Apache Commons and Utilities
Use of Apache Commons and Utilities
 
Lab4
Lab4Lab4
Lab4
 
Java Generics
Java GenericsJava Generics
Java Generics
 
ITGM #9 - ĐšĐŸĐČĐ°Ń€ĐœŃ‹Đč CodeType, ОлО ĐŸŃ‚ segfault'Đ° Đș Ń€Đ°Đ±ĐŸŃ‚Đ°ŃŽŃ‰Đ”ĐŒŃƒ ĐșĐŸĐŽŃƒ
ITGM #9 - ĐšĐŸĐČĐ°Ń€ĐœŃ‹Đč CodeType, ОлО ĐŸŃ‚ segfault'Đ° Đș Ń€Đ°Đ±ĐŸŃ‚Đ°ŃŽŃ‰Đ”ĐŒŃƒ ĐșĐŸĐŽŃƒITGM #9 - ĐšĐŸĐČĐ°Ń€ĐœŃ‹Đč CodeType, ОлО ĐŸŃ‚ segfault'Đ° Đș Ń€Đ°Đ±ĐŸŃ‚Đ°ŃŽŃ‰Đ”ĐŒŃƒ ĐșĐŸĐŽŃƒ
ITGM #9 - ĐšĐŸĐČĐ°Ń€ĐœŃ‹Đč CodeType, ОлО ĐŸŃ‚ segfault'Đ° Đș Ń€Đ°Đ±ĐŸŃ‚Đ°ŃŽŃ‰Đ”ĐŒŃƒ ĐșĐŸĐŽŃƒ
 
Picking Mushrooms after Cppcheck
Picking Mushrooms after CppcheckPicking Mushrooms after Cppcheck
Picking Mushrooms after Cppcheck
 
Mockito intro
Mockito introMockito intro
Mockito intro
 
JPC#8 Introduction to Java Programming
JPC#8 Introduction to Java ProgrammingJPC#8 Introduction to Java Programming
JPC#8 Introduction to Java Programming
 
E:\Plp 2009 2\Plp 9
E:\Plp 2009 2\Plp 9E:\Plp 2009 2\Plp 9
E:\Plp 2009 2\Plp 9
 
Java Simple Programs
Java Simple ProgramsJava Simple Programs
Java Simple Programs
 
Introduzione al TDD
Introduzione al TDDIntroduzione al TDD
Introduzione al TDD
 

Similar to Algoritmos sujei

java program assigment -2
java program assigment -2java program assigment -2
java program assigment -2Ankit Gupta
 
Presentation1 computer shaan
Presentation1 computer shaanPresentation1 computer shaan
Presentation1 computer shaanwalia Shaan
 
Tugas algoritma fibonacci
Tugas algoritma   fibonacciTugas algoritma   fibonacci
Tugas algoritma fibonacciMelina Krisnawati
 
the code below is a recommendation system application to suggest a s.pdf
the code below is a recommendation system application to suggest a s.pdfthe code below is a recommendation system application to suggest a s.pdf
the code below is a recommendation system application to suggest a s.pdfrajatchugh13
 
Chapter i(introduction to java)
Chapter i(introduction to java)Chapter i(introduction to java)
Chapter i(introduction to java)Chhom Karath
 
- the modification will be done in Main class- first, asks the use.pdf
- the modification will be done in Main class- first, asks the use.pdf- the modification will be done in Main class- first, asks the use.pdf
- the modification will be done in Main class- first, asks the use.pdfhanumanparsadhsr
 
Integration Project Inspection 3
Integration Project Inspection 3Integration Project Inspection 3
Integration Project Inspection 3Dillon Lee
 
Sam wd programs
Sam wd programsSam wd programs
Sam wd programsSoumya Behera
 
PrimeRange.java import java.util.Scanner;public class PrimeRan.pdf
PrimeRange.java import java.util.Scanner;public class PrimeRan.pdfPrimeRange.java import java.util.Scanner;public class PrimeRan.pdf
PrimeRange.java import java.util.Scanner;public class PrimeRan.pdfAnkitchhabra28
 
5 Rmi Print
5  Rmi Print5  Rmi Print
5 Rmi Printvaradasuren
 
JavaExamples
JavaExamplesJavaExamples
JavaExamplesSuman Astani
 
Wap to implement bitwise operators
Wap to implement bitwise operatorsWap to implement bitwise operators
Wap to implement bitwise operatorsHarleen Sodhi
 
Java Programs
Java ProgramsJava Programs
Java Programsvvpadhu
 
GeeCON 2012 Bad Tests, Good Tests
GeeCON 2012 Bad Tests, Good TestsGeeCON 2012 Bad Tests, Good Tests
GeeCON 2012 Bad Tests, Good TestsTomek Kaczanowski
 
java input & output statements
 java input & output statements java input & output statements
java input & output statementsVigneshManikandan11
 

Similar to Algoritmos sujei (20)

Problemas secuenciales.
Problemas secuenciales.Problemas secuenciales.
Problemas secuenciales.
 
Problemas secuenciales.
Problemas secuenciales.Problemas secuenciales.
Problemas secuenciales.
 
Problemas secuenciales.
Problemas secuenciales.Problemas secuenciales.
Problemas secuenciales.
 
Problemas secuenciales.
Problemas secuenciales.Problemas secuenciales.
Problemas secuenciales.
 
java program assigment -2
java program assigment -2java program assigment -2
java program assigment -2
 
Presentation1 computer shaan
Presentation1 computer shaanPresentation1 computer shaan
Presentation1 computer shaan
 
Tugas algoritma fibonacci
Tugas algoritma   fibonacciTugas algoritma   fibonacci
Tugas algoritma fibonacci
 
the code below is a recommendation system application to suggest a s.pdf
the code below is a recommendation system application to suggest a s.pdfthe code below is a recommendation system application to suggest a s.pdf
the code below is a recommendation system application to suggest a s.pdf
 
Chapter i(introduction to java)
Chapter i(introduction to java)Chapter i(introduction to java)
Chapter i(introduction to java)
 
- the modification will be done in Main class- first, asks the use.pdf
- the modification will be done in Main class- first, asks the use.pdf- the modification will be done in Main class- first, asks the use.pdf
- the modification will be done in Main class- first, asks the use.pdf
 
Integration Project Inspection 3
Integration Project Inspection 3Integration Project Inspection 3
Integration Project Inspection 3
 
Sam wd programs
Sam wd programsSam wd programs
Sam wd programs
 
PrimeRange.java import java.util.Scanner;public class PrimeRan.pdf
PrimeRange.java import java.util.Scanner;public class PrimeRan.pdfPrimeRange.java import java.util.Scanner;public class PrimeRan.pdf
PrimeRange.java import java.util.Scanner;public class PrimeRan.pdf
 
5 Rmi Print
5  Rmi Print5  Rmi Print
5 Rmi Print
 
JavaExamples
JavaExamplesJavaExamples
JavaExamples
 
Functional Programming
Functional ProgrammingFunctional Programming
Functional Programming
 
Wap to implement bitwise operators
Wap to implement bitwise operatorsWap to implement bitwise operators
Wap to implement bitwise operators
 
Java Programs
Java ProgramsJava Programs
Java Programs
 
GeeCON 2012 Bad Tests, Good Tests
GeeCON 2012 Bad Tests, Good TestsGeeCON 2012 Bad Tests, Good Tests
GeeCON 2012 Bad Tests, Good Tests
 
java input & output statements
 java input & output statements java input & output statements
java input & output statements
 

More from gersonjack

Propuesta..sujei
Propuesta..sujeiPropuesta..sujei
Propuesta..sujeigersonjack
 
Propuestos
PropuestosPropuestos
Propuestosgersonjack
 
Propuestos
PropuestosPropuestos
Propuestosgersonjack
 
Mayy para-enviar-1
Mayy para-enviar-1Mayy para-enviar-1
Mayy para-enviar-1gersonjack
 
Gaviota .algoritmos
Gaviota .algoritmosGaviota .algoritmos
Gaviota .algoritmosgersonjack
 
Ejercicios resueltos
Ejercicios resueltosEjercicios resueltos
Ejercicios resueltosgersonjack
 
Jimena resumen
Jimena resumenJimena resumen
Jimena resumengersonjack
 
Gerson jack
Gerson jackGerson jack
Gerson jackgersonjack
 
gerson jack
gerson jack gerson jack
gerson jack gersonjack
 
Kendal y kendel
Kendal y kendelKendal y kendel
Kendal y kendelgersonjack
 
El rol del analista de sistemas
El rol del analista de sistemasEl rol del analista de sistemas
El rol del analista de sistemasgersonjack
 
Boleta,factura u otros gerson
Boleta,factura u otros gersonBoleta,factura u otros gerson
Boleta,factura u otros gersongersonjack
 

More from gersonjack (12)

Propuesta..sujei
Propuesta..sujeiPropuesta..sujei
Propuesta..sujei
 
Propuestos
PropuestosPropuestos
Propuestos
 
Propuestos
PropuestosPropuestos
Propuestos
 
Mayy para-enviar-1
Mayy para-enviar-1Mayy para-enviar-1
Mayy para-enviar-1
 
Gaviota .algoritmos
Gaviota .algoritmosGaviota .algoritmos
Gaviota .algoritmos
 
Ejercicios resueltos
Ejercicios resueltosEjercicios resueltos
Ejercicios resueltos
 
Jimena resumen
Jimena resumenJimena resumen
Jimena resumen
 
Gerson jack
Gerson jackGerson jack
Gerson jack
 
gerson jack
gerson jack gerson jack
gerson jack
 
Kendal y kendel
Kendal y kendelKendal y kendel
Kendal y kendel
 
El rol del analista de sistemas
El rol del analista de sistemasEl rol del analista de sistemas
El rol del analista de sistemas
 
Boleta,factura u otros gerson
Boleta,factura u otros gersonBoleta,factura u otros gerson
Boleta,factura u otros gerson
 

Recently uploaded

Vip B Aizawl Call Girls #9907093804 Contact Number Escorts Service Aizawl
Vip B Aizawl Call Girls #9907093804 Contact Number Escorts Service AizawlVip B Aizawl Call Girls #9907093804 Contact Number Escorts Service Aizawl
Vip B Aizawl Call Girls #9907093804 Contact Number Escorts Service Aizawlmakika9823
 
The Economic History of the U.S. Lecture 20.pdf
The Economic History of the U.S. Lecture 20.pdfThe Economic History of the U.S. Lecture 20.pdf
The Economic History of the U.S. Lecture 20.pdfGale Pooley
 
Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...
Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...
Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...makika9823
 
VIP Kolkata Call Girl Jodhpur Park 👉 8250192130 Available With Room
VIP Kolkata Call Girl Jodhpur Park 👉 8250192130  Available With RoomVIP Kolkata Call Girl Jodhpur Park 👉 8250192130  Available With Room
VIP Kolkata Call Girl Jodhpur Park 👉 8250192130 Available With Roomdivyansh0kumar0
 
VIP Call Girls LB Nagar ( Hyderabad ) Phone 8250192130 | â‚č5k To 25k With Room...
VIP Call Girls LB Nagar ( Hyderabad ) Phone 8250192130 | â‚č5k To 25k With Room...VIP Call Girls LB Nagar ( Hyderabad ) Phone 8250192130 | â‚č5k To 25k With Room...
VIP Call Girls LB Nagar ( Hyderabad ) Phone 8250192130 | â‚č5k To 25k With Room...Suhani Kapoor
 
The Economic History of the U.S. Lecture 22.pdf
The Economic History of the U.S. Lecture 22.pdfThe Economic History of the U.S. Lecture 22.pdf
The Economic History of the U.S. Lecture 22.pdfGale Pooley
 
Lundin Gold April 2024 Corporate Presentation v4.pdf
Lundin Gold April 2024 Corporate Presentation v4.pdfLundin Gold April 2024 Corporate Presentation v4.pdf
Lundin Gold April 2024 Corporate Presentation v4.pdfAdnet Communications
 
Bladex Earnings Call Presentation 1Q2024
Bladex Earnings Call Presentation 1Q2024Bladex Earnings Call Presentation 1Q2024
Bladex Earnings Call Presentation 1Q2024Bladex
 
Quarter 4- Module 3 Principles of Marketing
Quarter 4- Module 3 Principles of MarketingQuarter 4- Module 3 Principles of Marketing
Quarter 4- Module 3 Principles of MarketingMaristelaRamos12
 
05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx
05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx
05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptxFinTech Belgium
 
06_Joeri Van Speybroek_Dell_MeetupDora&Cybersecurity.pdf
06_Joeri Van Speybroek_Dell_MeetupDora&Cybersecurity.pdf06_Joeri Van Speybroek_Dell_MeetupDora&Cybersecurity.pdf
06_Joeri Van Speybroek_Dell_MeetupDora&Cybersecurity.pdfFinTech Belgium
 
Call US 📞 9892124323 ✅ Kurla Call Girls In Kurla ( Mumbai ) secure service
Call US 📞 9892124323 ✅ Kurla Call Girls In Kurla ( Mumbai ) secure serviceCall US 📞 9892124323 ✅ Kurla Call Girls In Kurla ( Mumbai ) secure service
Call US 📞 9892124323 ✅ Kurla Call Girls In Kurla ( Mumbai ) secure servicePooja Nehwal
 
02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptx
02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptx02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptx
02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptxFinTech Belgium
 
Interimreport1 January–31 March2024 Elo Mutual Pension Insurance Company
Interimreport1 January–31 March2024 Elo Mutual Pension Insurance CompanyInterimreport1 January–31 March2024 Elo Mutual Pension Insurance Company
Interimreport1 January–31 March2024 Elo Mutual Pension Insurance CompanyTyöelĂ€keyhtiö Elo
 
High Class Call Girls Nashik Maya 7001305949 Independent Escort Service Nashik
High Class Call Girls Nashik Maya 7001305949 Independent Escort Service NashikHigh Class Call Girls Nashik Maya 7001305949 Independent Escort Service Nashik
High Class Call Girls Nashik Maya 7001305949 Independent Escort Service NashikCall Girls in Nagpur High Profile
 
The Economic History of the U.S. Lecture 30.pdf
The Economic History of the U.S. Lecture 30.pdfThe Economic History of the U.S. Lecture 30.pdf
The Economic History of the U.S. Lecture 30.pdfGale Pooley
 
VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130
VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130
VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130Suhani Kapoor
 
Call Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur EscortsCall Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur Escortsranjana rawat
 

Recently uploaded (20)

Vip B Aizawl Call Girls #9907093804 Contact Number Escorts Service Aizawl
Vip B Aizawl Call Girls #9907093804 Contact Number Escorts Service AizawlVip B Aizawl Call Girls #9907093804 Contact Number Escorts Service Aizawl
Vip B Aizawl Call Girls #9907093804 Contact Number Escorts Service Aizawl
 
The Economic History of the U.S. Lecture 20.pdf
The Economic History of the U.S. Lecture 20.pdfThe Economic History of the U.S. Lecture 20.pdf
The Economic History of the U.S. Lecture 20.pdf
 
Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...
Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...
Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...
 
VIP Kolkata Call Girl Jodhpur Park 👉 8250192130 Available With Room
VIP Kolkata Call Girl Jodhpur Park 👉 8250192130  Available With RoomVIP Kolkata Call Girl Jodhpur Park 👉 8250192130  Available With Room
VIP Kolkata Call Girl Jodhpur Park 👉 8250192130 Available With Room
 
VIP Call Girls LB Nagar ( Hyderabad ) Phone 8250192130 | â‚č5k To 25k With Room...
VIP Call Girls LB Nagar ( Hyderabad ) Phone 8250192130 | â‚č5k To 25k With Room...VIP Call Girls LB Nagar ( Hyderabad ) Phone 8250192130 | â‚č5k To 25k With Room...
VIP Call Girls LB Nagar ( Hyderabad ) Phone 8250192130 | â‚č5k To 25k With Room...
 
The Economic History of the U.S. Lecture 22.pdf
The Economic History of the U.S. Lecture 22.pdfThe Economic History of the U.S. Lecture 22.pdf
The Economic History of the U.S. Lecture 22.pdf
 
Lundin Gold April 2024 Corporate Presentation v4.pdf
Lundin Gold April 2024 Corporate Presentation v4.pdfLundin Gold April 2024 Corporate Presentation v4.pdf
Lundin Gold April 2024 Corporate Presentation v4.pdf
 
Bladex Earnings Call Presentation 1Q2024
Bladex Earnings Call Presentation 1Q2024Bladex Earnings Call Presentation 1Q2024
Bladex Earnings Call Presentation 1Q2024
 
Quarter 4- Module 3 Principles of Marketing
Quarter 4- Module 3 Principles of MarketingQuarter 4- Module 3 Principles of Marketing
Quarter 4- Module 3 Principles of Marketing
 
05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx
05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx
05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx
 
06_Joeri Van Speybroek_Dell_MeetupDora&Cybersecurity.pdf
06_Joeri Van Speybroek_Dell_MeetupDora&Cybersecurity.pdf06_Joeri Van Speybroek_Dell_MeetupDora&Cybersecurity.pdf
06_Joeri Van Speybroek_Dell_MeetupDora&Cybersecurity.pdf
 
Call US 📞 9892124323 ✅ Kurla Call Girls In Kurla ( Mumbai ) secure service
Call US 📞 9892124323 ✅ Kurla Call Girls In Kurla ( Mumbai ) secure serviceCall US 📞 9892124323 ✅ Kurla Call Girls In Kurla ( Mumbai ) secure service
Call US 📞 9892124323 ✅ Kurla Call Girls In Kurla ( Mumbai ) secure service
 
02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptx
02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptx02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptx
02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptx
 
Interimreport1 January–31 March2024 Elo Mutual Pension Insurance Company
Interimreport1 January–31 March2024 Elo Mutual Pension Insurance CompanyInterimreport1 January–31 March2024 Elo Mutual Pension Insurance Company
Interimreport1 January–31 March2024 Elo Mutual Pension Insurance Company
 
High Class Call Girls Nashik Maya 7001305949 Independent Escort Service Nashik
High Class Call Girls Nashik Maya 7001305949 Independent Escort Service NashikHigh Class Call Girls Nashik Maya 7001305949 Independent Escort Service Nashik
High Class Call Girls Nashik Maya 7001305949 Independent Escort Service Nashik
 
The Economic History of the U.S. Lecture 30.pdf
The Economic History of the U.S. Lecture 30.pdfThe Economic History of the U.S. Lecture 30.pdf
The Economic History of the U.S. Lecture 30.pdf
 
VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130
VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130
VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130
 
Call Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur EscortsCall Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur Escorts
 
Commercial Bank Economic Capsule - April 2024
Commercial Bank Economic Capsule - April 2024Commercial Bank Economic Capsule - April 2024
Commercial Bank Economic Capsule - April 2024
 
Veritas Interim Report 1 January–31 March 2024
Veritas Interim Report 1 January–31 March 2024Veritas Interim Report 1 January–31 March 2024
Veritas Interim Report 1 January–31 March 2024
 

Algoritmos sujei

  • 1. ejercicio 01 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package porpuesto009; import java.io.*; import java.util.Scanner; /** * * @author gaviota */ public class Porpuesto009 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException { Scanner ap = new Scanner (System.in); double a, b ,c; System.out.println("Área y perĂ­metro de un Rectagulo"); System.out.println("Ingrese el valor de a"); a= ap.nextInt(); System.out.println("ingrese el valor de b"); b= ap.nextInt(); double area= a*b; double perimetro=2*a+2*b; System.out.println("El Área de un rectĂĄngulo es = " + area); System.out.println("El PerĂ­metro de un rectĂĄngulo es = " + perimetro); } } ejercicio 02 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema.nÂș2; import java.io.*; /** * * @author sujei */ public class ProblemaNÂș2 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException { int n1,n2,s;
  • 2. BufferedReader in =new BufferedReader(new InputStreamReader(System.in)); System.out.println("numero 1:"); n1 = Integer.parseInt(in.readLine()); System.out.println("numero 2:"); n2 = Integer.parseInt(in.readLine()); s=n1+n2; System.out.println(""); System.out.println("suma: " +s); } } ejercicio 03 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema3; import java.io.*; /** * * @author sujei */ public class Problema3 { /** * @param args the command line arguments */ public static void main(String[] args)throws IOException { //varible int n1,n2,c,r; BufferedReader in =new BufferedReader(new InputStreamReader(System.in)); System.out.println("numero 1:"); n1 = Integer.parseInt(in.readLine()); System.out.println("numero 2:"); n2 = Integer.parseInt(in.readLine()); //proceso c=n1/n2; r=n1%n2; //salida System.out.println(""); System.out.println("cociente: " +c); System.out.println("residuo: " +r); // TODO code application logic here }}
  • 3. ejercio 04 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema.pkg4; import java.io.*; /** * * @author sujei */ public class Problema4 { /** * @param args the command line arguments */ public static void main(String[] args)throws IOException { //variable float vv,igv,pv; //entrada BufferedReader in =new BufferedReader(new InputStreamReader(System.in)); System.out.println("valor de venta:"); vv =Float.parseFloat(in.readLine()); //proceso igv = vv *0.18f; pv = vv+ igv; //salida System.out.println(""); System.out.println("igv: " +igv); System.out.println("precio de venta: " +pv); // TODO code application logic here } } Ejercicio 5 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema004; import java.io.*; /** * * @author sujei */
  • 4. public class Problema004 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException { short a,n; int p; BufferedReader in =new BufferedReader(new InputStreamReader(System.in)); System.out.println("a: "); a=Short.parseShort(in.readLine()); System.out.println("n: "); n=Short.parseShort(in.readLine()); // TODO code application logic here p=(int)Math.pow((double)a, (double)n); System.out.println(""); System.out.println("Potencia: "+p); } } Ejercio 4 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema04; /** * * @author sujei */ public class Problema04 { /** * @param args the command line arguments */ public static void main(String[] args) { // TODO code application logic here } }
  • 5. Ejercicio5 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema05; import java.io.*; /** * * @author sujei */ public class PROBLEMA05 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException { short n,r; int a; BufferedReader in =new BufferedReader(new InputStreamReader(System.in)); System.out.println("a: "); a=Integer.parseInt(in.readLine()); System.out.println("n: "); n=Short.parseShort(in.readLine()); // TODO code application logic here r=(short)Math.pow((double)a, (1/(double)n)); System.out.println(""); System.out.println("RadicaciĂłn: "+r); // TODO code application logic here } } Ejercio 6 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema06; import java.io.*; /** * * @author sujei */ public class PROBLEMA06 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException { // TODO code application logic here int n, ni, r; BufferedReader in =new BufferedReader(new InputStreamReader(System.in));
  • 6. System.out.println("NĂșmero: "); n=Integer.parseInt(in.readLine()); r=n%10; n=n/10; ni=r*10; r=n%10; n=n/10; ni=(ni+r)*10; r=n%10; n=n/10; ni=(ni+r)*10; r=n%10; n=n/10; ni=(ni+r)*10; ni=ni+n; System.out.println(""); System.out.println("Inverso: " + ni); } } Ejercicio7 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema07; import java.io.*; /** * * @author sujei */ public class PROBLEMA07 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException { // TODO code application logic here int n,s; BufferedReader in =new BufferedReader(new InputStreamReader(System.in)); System.out.println("NĂșmero: "); n=Integer.parseInt(in.readLine()); s=(n*(n+1))/2; System.out.println(""); System.out.println("Suma: " + s); }
  • 7. }ejercicio 8 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema8; import java.io.*; /** * * @author sujei */ public class Problema8 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException { float c, r, t, i, m; BufferedReader in =new BufferedReader(new InputStreamReader(System.in)); System.out.println("Capital: "); c=Float.parseFloat(in.readLine()); System.out.println("Tasa de interes: "); r=Float.parseFloat(in.readLine()); System.out.println("Tiempo: "); t=Float.parseFloat(in.readLine()); m=(float)(Math.pow((double)(1+r/100),(double)t))*c; i=m-c; System.out.println(""); System.out.println("Interes: " + i); System.out.println("Monto: " + m); } } Ejercicio10 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema10; import java.io.*; /** * * @author sujei */ public class Problema10 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException {
  • 8. final int HORA=3600; final int MINUTO=60; int t,h,m,s; BufferedReader in =new BufferedReader(new InputStreamReader(System.in)); System.out.println("Tiempo en segundos: "); t=Integer.parseInt(in.readLine()); h=t/HORA; //t=t%HORA; m=t/MINUTO; s=t; System.out.println(""); System.out.println("Horas: "+h); System.out.println("Minutos: "+m); System.out.println("Segundos: "+s); // TODO code application logic here } } Ejercicio11 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema11; import java.io.*; /** * * @author sujei */ public class Problema11 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException { int a,b,n1,n2; BufferedReader in =new BufferedReader(new InputStreamReader(System.in)); System.out.println("NĂșmero1: "); a=Integer.parseInt(in.readLine()); System.out.println("NĂșmero2: "); b=Integer.parseInt(in.readLine()); n1=a+b; n2=a-b; System.out.println(""); System.out.println("Suma: " + n1); System.out.println("Resta: " + n2); // TODO code application logic here }
  • 9. } Ejercicio 12 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema12; import java.io.*; /** * * @author sujei */ public class Problema12 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException { int a,b; BufferedReader in =new BufferedReader(new InputStreamReader(System.in)); a=Integer.parseInt(in.readLine()); b=Integer.parseInt(in.readLine()); String x = Integer.toString(a); String y = Integer.toString(b); System.out.println("el 1er nĂșmero ingresado tiene: " + x.length() + " dĂ­gitos"); System.out.println("el 2do nĂșmero ingresado tiene: " + y.length() + " dĂ­gitos"); // TODO co de application logic here } } ejecicio /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema012; import java.io.*; /** * * @author sujei */ public class Problema012 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException{ int n; String r = ""; BufferedReader in=new BufferedReader(new InputStreamReader(System.in)); System.out.println("NĂșmero: "); n=(int)Integer.parseInt(in.readLine()); if (n>0)
  • 10. ejercicio13 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema013; import java.util.Scanner; /** * * @author sujei */ public class Problema013 { /** * @param args the command line arguments */ public static void main(String[] args) { char c; //String r=""; System.out.println("Caracter"); Scanner teclado=new Scanner(System.in); c=teclado.next().charAt(0); if(c=='a'||c=='e'||c=='i'||c=='o'||c=='u'||c=='A'||c=='E'||c=='I'||c=='O' ||c=='U'){ //r="es vocal";} System.out.println("ES VOCAL"); } else{ //r="no es vocal"; } System.out.println("NO ES VOCAL"); }//System.out.println("la letra ingresada "+r); } } { r="POSITIVO"; } if (n<0) { r="NEGATIVO"; } if(n==0) { r="NEUTRO"; } System.out.println(""); System.out.println("Resultado: "+r); } }
  • 11. ejercicio /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema13; import java.io.*; /** * * @author sujei */ public class Problema13 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException { final int METRO=1000; final int DECIMETRO=100; final int CENTIMETRO=10; int mm,m,d,c; BufferedReader in =new BufferedReader(new InputStreamReader(System.in)); System.out.println("Cantidad de milĂ­metros: "); mm=Integer.parseInt(in.readLine()); m=mm/METRO; d=mm/DECIMETRO; c=mm/CENTIMETRO; System.out.println(""); System.out.println("Metros: "+m); System.out.println("DecĂ­metros: "+d); System.out.println("CentĂ­metros: "+c); System.out.println("MilĂ­metros: "+mm); // TODO code application logic here } } Ejercicio 14 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema14; import java.io.*; /** * * @author gaviota */ public class PROBLEMA14 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException {
  • 12. double a, b, c, d, e; BufferedReader in =new BufferedReader(new InputStreamReader(System.in)); System.out.println("Ingresa un nĂșmero, serĂĄ el valor de a "); a=Integer.parseInt(in.readLine()); System.out.println("Ingresa un nĂșmero, serĂĄ el valor de b "); b=Integer.parseInt(in.readLine()); System.out.println("Ingresa un nĂșmero, serĂĄ el valor de c "); c=Integer.parseInt(in.readLine()); d=(4*(a*a*a*a)+(3*b*a)+(b*b))/(a*a-b*b); e=((3*(c*c))+a+b)/4; System.out.println(""); System.out.println("El resultado de la fĂłrmula siguiente c=(4*a^4+3*b*a+b^2)/a^2-b^2, es: "+d); System.out.println("El resultado de la fĂłrmula siguiente d=(3*c^2+a+b)/4, es: "+e); // TODO code application logic here } } Ejercicio15 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema015; import java.io.*; /** * * @author sujei */ public class PROBLEMA015 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException{ // TODO code application logic here int n; String r; BufferedReader in=new BufferedReader(new InputStreamReader(System.in)); System.out.println("NĂșmero: "); n=Integer.parseInt(in.readLine()); if(n%2==0) { r= "PAR"; } else { r= "IMPAR"; } System.out.println("");
  • 13. System.out.println("Resultado: " + r); System.out.println(); } } ejercicio /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema15; import java.io.*; /** * * @author sujei */ public class Problema15 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException { int a=1, b=2, c=3, d=4; int s=a+b+c+d; double porcentaje_a=(double)(a*100)/s; double porcentaje_b=(double)(b*100)/s; double porcentaje_c=(double)(c*100)/s; double porcentaje_d=(double)(d*100)/s; System.out.println(""); System.out.println("La variable "a" representa el: "+porcentaje_a+"% de "+s); System.out.println("La variable "b" representa el: "+porcentaje_b+"% de "+s); System.out.println("La variable "c" representa el: "+porcentaje_c+"% de "+s); System.out.println("La variable "d" representa el: "+porcentaje_d+"% de "+s); // TODO code application logic here } }
  • 14. Ejercicio 16 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema016; import java.io.*; /** * * @author sujei */ public class PROBLEMA016 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException{ int n1,n2,n3,m; BufferedReader in=new BufferedReader(new InputStreamReader(System.in)); System.out.println("NĂșmero 1: "); n1= Integer.parseInt(in.readLine()); System.out.println("NĂșmero 2: "); n2=Integer.parseInt(in.readLine()); System.out.println("NĂșmero 3: "); n3= Integer.parseInt(in.readLine()); if (n1>n2) { if(n1>n3) { m=n1; } else { m=n3; } } else { if(n2>n3) { m=n2; } else { m=n3; } } System.out.println(""); System.out.println("Mayor: " +m); } }
  • 15. Ejercicio17 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema017; import java.io.*; /** * * @author sujei */ public class PROBLEMA017 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException{ int n,r; BufferedReader in=new BufferedReader(new InputStreamReader(System.in)); System.out.println("NĂșmero: "); n = Integer.parseInt(in.readLine()); if (!(n%2==0)) { r=n*2; } else { r=n*3; } System.out.println(""); System.out.println("Resultado: " + r); System.out.println(); } } Ejercicio18 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema18; import java.io.*; /** * * @author sujei */ public class Problema18 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException { double f,k,c; BufferedReader in =new BufferedReader(new InputStreamReader(System.in)); System.out.println("Grados Fahrenheit: ");
  • 16. f=Integer.parseInt(in.readLine()); c = (f-32)/1.8; k = (f-32)*5/9+273.15; System.out.println(""); System.out.println("A grados Celsius: "+c); System.out.println("A grados Kelvin: "+k); } } dReader(new InputStreamReader(System.in)); System.out.println("Grados Sexagesimales: "); s=Integer.parseInt(in.readLine()); c=s*200/180; System.out.println(""); System.out.println("A grados Centesimales: "+c); } } Ejercicio 19 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema019; import java.io.*; /** * * @author sujei */ public class Problema019 { /** * @param args the command line arguments */ public static void main(String[] args)throws IOException{ final float D1=0.1F; final float D2=0.2F; final float IGV=0.18F; float c,m_d, m_igv, p; BufferedReader in=new BufferedReader(new InputStreamReader(System.in)); System.out.println("Consumo: "); c=(float)Integer.parseInt(in.readLine()); if(c<=100) { m_d=c * D1; } else {
  • 17. m_d=c * D2; } m_igv=(c-m_d) * IGV; p= c - m_d + m_igv; System.out.println(""); System.out.println("Monto descuento: " + m_d); System.out.println("Impuesto IGV: " + m_igv); System.out.println("Importe a pagar: " + p); System.out.println(); } } Ejercicio20 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema20; import java.io.*; /** * * @author sujei */ public class Problema20 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException { double s,c; BufferedReader in =new BufferedReader(new InputStreamReader(System.in)); System.out.println("Grados Sexagesimales: "); s=Integer.parseInt(in.readLine()); c=s*200/180; System.out.println(""); System.out.println("A grados Centesimales: "+c); } } EJERCICIO21 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema21; import java.io.*; /** * * @author CARLITA
  • 18. */ public class Problema21 { /** * @param args the command line arguments */ public static void main(String[] args)throws IOException { double s; BufferedReader in =new BufferedReader(new InputStreamReader(System.in)); System.out.println("incendiohohoohho"); EJERCICIO22 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema022; import java.util.Scanner; /** * * @author SUJEI */ public class Problema022 { /** * @param args the command line arguments */ public static void main(String[] args){ Scanner in =new Scanner(System.in); final float DESC_G = 0.15F; final float DESC_A = 0.2F; final float REC_G = 0.1F; final float REC_A = 0.05F; //variables float mc, m, tp; //char tc,fp; String r ; String tc; String fp; System.out.println("Monto de compra: "); mc=in.nextFloat(); System.out.println("Tipo de cliente: "); tc =in.next(); System.out.println("Forma de pago: "); fp=in.next(); if(tc=="G") { if(fp=="C") { m = mc * DESC_G; tp = mc - m;
  • 19. r = "DESCUENTO 15%"; } else { m = mc * REC_G; tp = mc + m; r = "RECARGO 10%"; } } else { if (fp=="C") { m = mc * DESC_A; tp = mc - m; ejercicio23 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema023; import java.io.*; /** * * @author sujei */ public class PROBLEMA023 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException{ float a,b,x; BufferedReader in=new BufferedReader(new InputStreamReader(System.in)); System.out.println("a: "); a=Float.parseFloat(in.readLine()); System.out.println("b: "); b=Float.parseFloat(in.readLine()); if(a!=0) { x=-b/a; } else { x=0; } System.out.println(""); System.out.println("x: " + x); System.out.println(); } }
  • 20. Ejercicio24 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema024; import java.io.*; /** * * @author sujei */ public class Problema024 { /** * @param args the command line arguments */ public static void main(String[] args)throws IOException { double a,b,c,d,x1,x2; BufferedReader in=new BufferedReader(new InputStreamReader(System.in)); System.out.println("a: "); a=(double) Integer.parseInt(in.readLine()); System.out.println("b: "); b=(double)Integer.parseInt(in.readLine()); System.out.println("c: "); c=(double) Integer.parseInt(in.readLine()); d = Math.pow(b,2)-4*c; if(a!=0 && d>=0) { x1 = (-b+Math.pow(d,(1.0/2)))/2*a; x2 = (-b-Math.pow(d,(1.0/2)))/2*a; } else { x1 = 0; x2 = 0; } System.out.println(""); System.out.println("x1: " + x1); System.out.println("x2: " + x2); System.out.println(); } } Ejercicio25 /* * To change this template, choose Tools | Templates * and open the template in the editor. */ package problema0025; import java.io.*; /** * * @author sujei */
  • 21. public class Problema0025 { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException { int h,m,s; BufferedReader in=new BufferedReader(new InputStreamReader(System.in)); System.out.println("Hora: "); h= Integer.parseInt(in.readLine()); System.out.println("Minuto: "); m=Integer.parseInt(in.readLine()); System.out.println("Segundo: "); s= Integer.parseInt(in.readLine()); s+=1; if (s==60) { s=0; m+=1; if(m==60) { m=0; h+=1; if(h==24) { h=0; } } } System.out.println(""); System.out.println("Hora: " + h); System.out.println("Minuto: " + m); System.out.println("Segundo: " + s); System.out.println(); } }