Comprobaciones hechas

parent ef86bf02
public class Carta { public class Carta {
public String valor; public String valor;
public String palo; public String palo;
public Carta()
{ public Carta()
{
}
}
public Carta(String completo)
public Carta(String completo)
{ {
this.valor = String.valueOf(completo.charAt(0)); this.valor = String.valueOf(completo.charAt(0));
this.palo = String.valueOf(completo.charAt(1)); this.palo = String.valueOf(completo.charAt(1));
} }
String valorPalo() String valorPalo()
{ {
return this.valor + this.palo; return this.valor + this.palo;
} }
//aa
} }
This diff is collapsed. Click to expand it.
public class Poker {
public static void main(String[] args) {
// --------------------------------------
Carta carta1 = new Carta("AC");
Carta carta2 = new Carta("2C");
Carta carta3 = new Carta("3S");
Carta carta4 = new Carta("5C");
Carta carta5 = new Carta("4C");
Jugada jugada1 = new Jugada();
jugada1.ejecutarComprobaciones(carta1, carta2, carta3, carta4, carta5);
jugada1.imprimirResultado();
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment