結果
| 問題 | 
                            No.188 HAPPY DAY
                             | 
                    
| コンテスト | |
| ユーザー | 
                             | 
                    
| 提出日時 | 2023-04-12 19:12:07 | 
| 言語 | Java  (openjdk 23)  | 
                    
| 結果 | 
                             
                                WA
                                 
                             
                            
                         | 
                    
| 実行時間 | - | 
| コード長 | 691 bytes | 
| コンパイル時間 | 4,259 ms | 
| コンパイル使用メモリ | 73,896 KB | 
| 実行使用メモリ | 54,244 KB | 
| 最終ジャッジ日時 | 2024-10-08 18:27:05 | 
| 合計ジャッジ時間 | 3,260 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge4 / judge1 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | WA * 1 | 
ソースコード
import java.util.Scanner;
import java.util.Calendar;
 
public class Main {
    public static void main(String[] args) throws Exception {
        Calendar cl = Calendar.getInstance();
      
        int y = 2015;
        int m = 1;
        cl.set(y,m-1,1);
        int d = cl.getActualMaximum(Calendar.DAY_OF_MONTH);
        
        int tens = d / 10; 
        int ones = d % 10;
        int count = 0;
        
        //12回繰り返す
        for(m=1;m<=12;m++){
        	////2015年のカレンダーの日次回数繰り返す
        	for(int x= 1;x<=d;x++){
        		if(m==tens+ones){
        		count +=1;
        		}
        	}
        }
        System.out.println(count);
    }
}