Compare commits
1
Commits
d689f80fbc
..
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
de0900d1d2 |
@@ -7,13 +7,17 @@ public class P481_Ajedrez {
|
|||||||
public static void main(String[] args) {
|
public static void main(String[] args) {
|
||||||
Scanner sc = new Scanner(System.in);
|
Scanner sc = new Scanner(System.in);
|
||||||
int h = 0, v = 0;
|
int h = 0, v = 0;
|
||||||
|
boolean detener = false;
|
||||||
do {
|
do {
|
||||||
h = sc.nextInt();
|
h = sc.nextInt();
|
||||||
v = sc.nextInt();
|
v = sc.nextInt();
|
||||||
if (h == 0 && v == 0) break;
|
if (h == 0 && v == 0) {
|
||||||
|
detener = true;
|
||||||
|
} else {
|
||||||
char letra = (char) ((8 - h) + (int) ('a'));
|
char letra = (char) ((8 - h) + (int) ('a'));
|
||||||
System.out.printf("%c%d\n", letra, v);
|
System.out.printf("%c%d\n", letra, v);
|
||||||
} while (true);
|
}
|
||||||
|
} while (!detener);
|
||||||
sc.close();
|
sc.close();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user