
エントリーの編集

エントリーの編集は全ユーザーに共通の機能です。
必ずガイドラインを一読の上ご利用ください。
Python json.loads shows ValueError: Extra data
記事へのコメント0件
- 注目コメント
- 新着コメント
このエントリーにコメントしてみましょう。
注目コメント算出アルゴリズムの一部にLINEヤフー株式会社の「建設的コメント順位付けモデルAPI」を使用しています

- バナー広告なし
- ミュート機能あり
- ダークモード搭載
関連記事
Python json.loads shows ValueError: Extra data
I am getting some data from a JSON file "new.json", and I want to filter some data and store it i... I am getting some data from a JSON file "new.json", and I want to filter some data and store it into a new JSON file. Here is my code: import json with open('new.json') as infile: data = json.load(infile) for item in data: iden = item.get["id"] a = item.get["a"] b = item.get["b"] c = item.get["c"] if c == 'XYZ' or "XYZ" in data["text"]: filename = 'abc.json' try: outfile = open(filename,'ab') exce