Submission #12680762


Source Code Expand

Copy
x = gets.to_i

d = 100
ans = 0

loop do
  ans += 1
  d += (d * 0.01).floor

  if d >= x
    puts ans
    break
  end
end

Submission Info

Submission Time
Task B - 1%
User cheezenaan
Language Ruby (2.7.1)
Score 200
Code Size 135 Byte
Status
Exec Time 54 ms
Memory 14336 KB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 200 / 200
Status
× 3
× 17
Set Name Test Cases
Sample 00-sample-01.txt, 00-sample-02.txt, 00-sample-03.txt
All 00-sample-01.txt, 00-sample-02.txt, 00-sample-03.txt, 10-random-01.txt, 10-random-02.txt, 10-random-03.txt, 10-random-04.txt, 10-random-05.txt, 20-less-01.txt, 20-less-02.txt, 20-less-03.txt, 21-equal-01.txt, 21-equal-02.txt, 21-equal-03.txt, 22-greater-01.txt, 22-greater-02.txt, 22-greater-03.txt
Case Name Status Exec Time Memory
00-sample-01.txt 52 ms 13972 KB
00-sample-02.txt 51 ms 14332 KB
00-sample-03.txt 51 ms 14128 KB
10-random-01.txt 53 ms 14000 KB
10-random-02.txt 52 ms 14236 KB
10-random-03.txt 53 ms 14204 KB
10-random-04.txt 51 ms 14160 KB
10-random-05.txt 51 ms 14220 KB
20-less-01.txt 52 ms 14228 KB
20-less-02.txt 54 ms 14140 KB
20-less-03.txt 51 ms 14132 KB
21-equal-01.txt 53 ms 14228 KB
21-equal-02.txt 52 ms 14224 KB
21-equal-03.txt 54 ms 14284 KB
22-greater-01.txt 51 ms 14072 KB
22-greater-02.txt 53 ms 14336 KB
22-greater-03.txt 51 ms 14272 KB