Submission #3704928


Source Code Expand

#
# File    : B2.rb
# Author  : Kazune Takahashi
# Created : 2018-12-2 21:33:52
# Powered by Visual Studio Code
#

s = gets.chomp
ans = []
for i in 0...s.size - 2
  ans << (753 - s[i...i + 3].to_i).abs
end
puts ans.min

Submission Info

Submission Time
Task B - 754
User kazunetakahashi
Language Ruby (2.3.3)
Score 200
Code Size 234 Byte
Status AC
Exec Time 7 ms
Memory 1788 KB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 200 / 200
Status
AC × 3
AC × 10
Set Name Test Cases
Sample a01, a02, a03
All a01, a02, a03, b04, b05, b06, b07, b08, b09, b10
Case Name Status Exec Time Memory
a01 AC 7 ms 1788 KB
a02 AC 7 ms 1788 KB
a03 AC 7 ms 1788 KB
b04 AC 7 ms 1788 KB
b05 AC 7 ms 1788 KB
b06 AC 7 ms 1788 KB
b07 AC 7 ms 1788 KB
b08 AC 7 ms 1788 KB
b09 AC 7 ms 1788 KB
b10 AC 7 ms 1788 KB