2891. Method Chaining

Обновлено: 2024-03-12
1 мин
[]

Содержание

LeetCode problem 2891

import pandas as pd


def findHeavyAnimals(animals: pd.DataFrame) -> pd.DataFrame:
    return animals[animals['weight'] > 100].sort_values('weight', ascending=False)[
        ['name']
    ]