Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class Condicionalbooleano {
- public static void main (String [] args)
- {
- int horas = 2, minutos = 1, segundos = 14;
- System.OUT.println("Quedan " +
- String.valueOf(horas) + " " + ((horas>1)?"horas":"hora") + " " +
- String.valueOf(minutos) + " " + ((minutos>1)?"minutos":"minuto") + " " +
- String.valueOf(segundos) + " " + ((segundos>1?"segundos":"segundo"))
- );
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement