0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

paizaラーニング問題集「【文字列 2】super long int」を解いてみた

Posted at

▼考え方

題意の通りコーディングしました。

▼コード

########## 処理0(準備) インプット ###########

X = input()

########## 処理1 hash(X)の値を求める処理 ###########

print(int(X[0:8])+int(X[8:16])+int(X[16:24])+int(X[24:32]))

▼参考
X = "12345678123456781234567812345678"のとき、X[0:8]、X[8:16]、X[16:24]、X[24:32]はすべて"12345678"になります。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?