CALCULOS JAVA code example
Example: CalculoIVE java
import java.util.Scanner;
public class CalculoIVE {
public static void main(String[] args) {
Scanner teclado = new Scanner(System.in);
//D
double prezo = 0;
double ive = 0;
double pfinal = 0;
//E
System.out.println("Introduza prezo sen IVE (€) : ");
prezo = teclado.nextDouble();
System.out.println("Introduza IVE (%) : ");
ive = teclado.nextDouble();
//P
pfinal = prezo * (1 + (ive / 100));
//S
System.out.println("Importe con IVE = " + pfinal + "€");
}
}