結果
問題 |
No.8020 サンシャイン◯崎
|
ユーザー |
|
提出日時 | 2023-11-05 18:45:13 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 270 ms / 1,000 ms |
コード長 | 863 bytes |
コンパイル時間 | 2,408 ms |
コンパイル使用メモリ | 82,704 KB |
実行使用メモリ | 44,560 KB |
最終ジャッジ日時 | 2024-09-25 22:38:55 |
合計ジャッジ時間 | 7,532 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 20 |
ソースコード
import java.util.*; public class Main { public static void main(String[] args) throws Exception { Scanner sc = new Scanner(System.in); StringBuilder ikezaki = new StringBuilder(); while(sc.hasNext()){ ikezaki.append(sc.next()); } Map<Character , Integer> YEAH = new LinkedHashMap<>(); YEAH.put('Y',0); YEAH.put('E',0); YEAH.put('A',0); YEAH.put('H',0); YEAH.put('!',0); for(int i = 0 ; i < ikezaki.length() ; i++){ char c = ikezaki.charAt(i); YEAH.put(c , YEAH.get(c) + 1); } for(Map.Entry<Character, Integer> entry : YEAH.entrySet()){ System.out.print(entry.getValue()+" "); } System.out.println(); //ピーナッツ! } }