LoginSignup
0
0

More than 1 year has passed since last update.

paiza練習問題(ランクC:リスト内の値の比較)

Posted at

目次

  • 解いた問題
  • 参考にしたサイト
  • 振返り
  • 参考コード

本文

  • 解いた問題

  • 参考にしたサイト

  • 振返り
    リスト内の要素が数字の場合すぐにint型に変えたくなるが解説を見ると必要なときに都度int型に変更するのでもいいのかも。上記参考サイトはリスト内のstr型をint型に変更する単に参照しました。

  • 参考コード(文字列リストを数値型に変換)

a = ["1", "2", "3"]
int_a = [int(i) for i in a]
print(int_a)
#[1, 2, 3]
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