😎풀이

  1. employees 데이터를 DataFrame 객체로 변환
  2. head 메서드를 사용해 위에서부터 3개의 행만 필터링하여 반환환
import pandas as pd

def selectFirstRows(employees: pd.DataFrame) -> pd.DataFrame:
    employeesDF = pd.DataFrame(employees)
    return employeesDF.head(3)
profile
내 지식을 공유할 수 있는 대담함

0개의 댓글