[백준] 10250번 : ACM 호텔 - Java(자바)

강재원·2022년 10월 2일
0

[코딩테스트] Java

목록 보기
88/200



https://www.acmicpc.net/problem/10250

import java.util.*;
public class Main {
    public static void main(String args[]) {
        Scanner s=new Scanner(System.in);
        int t=s.nextInt();
        for(int i=0;i<t;i++){
            int h=s.nextInt();
            int w=s.nextInt();
            int n=s.nextInt();
            if(n%h==0) System.out.format("%d%02d\n",h,n/h);
            else   System.out.format("%d%02d\n",n%h,(n/h)+1);
        }
    }
}
profile
개념정리 & 문법 정리 & 알고리즘 공부

0개의 댓글