Submission #732214
Source Code Expand
w,h = STDIN.gets.split.map{|n| n.to_i} class Aspect def initialize(w, h) raise "invalide wide #{w}" if h > w || w > 100000 raise "invalide height #{h}" if h < 1 @w = w @h = h end def aspect if @w % 16 == 0 && @h % 9 == 0 "16:9" else "4:3" end end end a = Aspect.new(w,h) puts a.aspect
Submission Info
Submission Time | |
---|---|
Task | A - テレビ |
User | buty4649 |
Language | Ruby (2.3.3) |
Score | 100 |
Code Size | 359 Byte |
Status | AC |
Exec Time | 18 ms |
Memory | 1788 KB |
Judge Result
Set Name | Sample | All | ||||
---|---|---|---|---|---|---|
Score / Max Score | 0 / 0 | 100 / 100 | ||||
Status |
|
|
Set Name | Test Cases |
---|---|
Sample | example_01.txt, example_02.txt, example_03.txt |
All | 16_9_01.txt, 16_9_02.txt, 16_9_03.txt, 16_9_04.txt, 16_9_05.txt, 16_9_06.txt, 16_9_07.txt, 16_9_08.txt, 16_9_09.txt, 16_9_10.txt, 16_9_max.txt, 4_3_01.txt, 4_3_02.txt, 4_3_03.txt, 4_3_04.txt, 4_3_05.txt, 4_3_06.txt, 4_3_07.txt, 4_3_08.txt, 4_3_09.txt, 4_3_10.txt, 4_3_max.txt, example_01.txt, example_02.txt, example_03.txt |
Case Name | Status | Exec Time | Memory |
---|---|---|---|
16_9_01.txt | AC | 17 ms | 1788 KB |
16_9_02.txt | AC | 16 ms | 1788 KB |
16_9_03.txt | AC | 17 ms | 1788 KB |
16_9_04.txt | AC | 16 ms | 1788 KB |
16_9_05.txt | AC | 16 ms | 1788 KB |
16_9_06.txt | AC | 17 ms | 1788 KB |
16_9_07.txt | AC | 17 ms | 1788 KB |
16_9_08.txt | AC | 17 ms | 1788 KB |
16_9_09.txt | AC | 17 ms | 1788 KB |
16_9_10.txt | AC | 17 ms | 1788 KB |
16_9_max.txt | AC | 17 ms | 1788 KB |
4_3_01.txt | AC | 17 ms | 1788 KB |
4_3_02.txt | AC | 17 ms | 1788 KB |
4_3_03.txt | AC | 17 ms | 1788 KB |
4_3_04.txt | AC | 17 ms | 1788 KB |
4_3_05.txt | AC | 17 ms | 1788 KB |
4_3_06.txt | AC | 17 ms | 1788 KB |
4_3_07.txt | AC | 18 ms | 1788 KB |
4_3_08.txt | AC | 17 ms | 1788 KB |
4_3_09.txt | AC | 17 ms | 1788 KB |
4_3_10.txt | AC | 18 ms | 1788 KB |
4_3_max.txt | AC | 18 ms | 1788 KB |
example_01.txt | AC | 18 ms | 1788 KB |
example_02.txt | AC | 18 ms | 1788 KB |
example_03.txt | AC | 18 ms | 1788 KB |