結果
| 問題 | No.67 よくある棒を切る問題 (1) | 
| コンテスト | |
| ユーザー |  takakin | 
| 提出日時 | 2020-05-03 20:23:24 | 
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) | 
| 結果 | 
                                AC
                                 
                             | 
| 実行時間 | 2,563 ms / 5,000 ms | 
| コード長 | 312 bytes | 
| コンパイル時間 | 341 ms | 
| コンパイル使用メモリ | 12,288 KB | 
| 実行使用メモリ | 32,728 KB | 
| 最終ジャッジ日時 | 2025-03-03 11:38:45 | 
| 合計ジャッジ時間 | 44,360 ms | 
| ジャッジサーバーID (参考情報) | judge1 / judge2 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | AC * 30 | 
ソースコード
import sys
input=lambda: sys.stdin.readline().rstrip()
n=int(input())
L=[int(i) for i in input().split()]
k=int(input())
def chk(x):
  ct=0
  for ln in L:
    ct+=int(ln/x)
  return ct>=k
l,r=0,max(L)
t=0
while r-l>10**(-9) and t<=10**2:
  mid=(l+r)/2
  if chk(mid):
    l=mid
  else:
    r=mid
  t+=1
print(l)
            
            
            
        