
22/10/2011, 14:49
|
| | Fecha de Ingreso: octubre-2011
Mensajes: 9
Antigüedad: 13 años, 4 meses Puntos: 2 | |
Respuesta: Ejercicio JAVA Billetes/monedas ¿Así voy bien? xD
import java.util.Scanner;
public class Ejercicio15 {
public static void main(String[] args) {
double precio;
double billetes;
double monedas;
precio = (double)(Math.random()*100);
Scanner teclado = new Scanner(System.in);
System.out.println("Artículo: ");
System.out.print (" Precio del artículo: ");
precio = teclado.nextFloat();
System.out.println (" Billetes utilizados: ");
billetes = teclado.nextFloat();
System.out.println (" Monedas utilizadas: ");
monedas = teclado.nextFloat();
}
} |