import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int t = sc.nextInt();
int x, y; // x : 엘리베이터로부터의 거리, y : 층
while(t > 0) {
int h = sc.nextInt();
int w = sc.nextInt();
int n = sc.nextInt();
if(n % h == 0) { // h층에 배정될 경우
y = h;
x = n / h;
}
else {
y = n % h;
x = n / h + 1;
}
System.out.println(y * 100 + x); // yyxx호 or yxx호
t--;
}
sc.close();
}
}
'Algorithm > 백준+프로그래머스+SWEA+정올+구름' 카테고리의 다른 글
[Algorithm] 백준 10870 피보나치 수 (0) | 2021.03.25 |
---|---|
[Algorithm] 백준 1193 분수찾기 (0) | 2021.03.25 |
[Algorithm] 백준 2577 숫자의 개수 (0) | 2021.03.25 |
[Algorithm] 백준 2884 알람 시계 (0) | 2021.03.25 |
[Algorithm] 백준 2753 윤년 (0) | 2021.03.25 |