AIに聞いた結果 >>819
合っているかはわからん

import urllib
import json
import pandas as pd
response = urllib.request.urlopen('https://raw.githubusercontent.com/fanzeyi/pokemon.json/master/pokedex.json')
content = response.read()
jpk = json.loads(content)
#print(jpk)
df = pd.DataFrame(jpk)
df['name']=df['name'].apply(lambda x: x['japanese'])
df=df.join(df["base"].apply(pd.Series)).drop(columns=["base"])

#火(Fire)と飛翔(Flying)の属性を持ったポケモンの数を表示
target_types = ['Fire','Flying']
count = sum([all(value in row for value in target_types) for row in df['type']])
print("typeがFireとFlyingのポケモンの数",count)

#消防士向きのポケモンを判定する  図鑑番号を指定して  水(Water)のタイプをもっていて、すばやさが平均以上の  ポケモンであれば、採用と表示する
target_types = ["Water"]
m_speed=df["Speed"].mean()
filtered_df = df[df.apply(lambda row: all(value in row['type'] for value in target_types) and row['Speed'] >= m_speed, axis=1)]
print("消防士向きのポケモン\n",list(filtered_df["name"]))
#発電向きのポケモンを判定する  図鑑番号を指定して  でんき(Electric)のタイプをもっていて、ぼうぎょりょくが中央値以上の  ポケモンであれば、採用と表示する
target_types = ["Electric"]
m_defense=df["Defense"].median()
filtered_df = df[df.apply(lambda row: all(value in row['type'] for value in target_types) and row['Defense'] >= m_defense, axis=1)]
print("発電向きのポケモン\n",list(filtered_df["name"]))

#typeがFireとFlyingのポケモンの数 6
# 消防士向きのポケモン ['カメックス', 'ゴルダック', 'ニョロモ', 'ニョロゾ', 'ニョロボン', 略
# 発電向きのポケモン ['コイル', 'レアコイル', 'マルマイン', 'サンダー', 'デンリュウ', 'ライコウ', 略