StripeOA #5
Cuisine Count (Pandas)
估计简单非算法题评测数据准备中,可先阅读题面
Dataframe df with columns restaurant_id, location_code, cuisines (space-separated lowercase strings):
- Drop restaurants offering fewer than 3 cuisines.
- Strip
location_codeto alphanumeric characters only. - For each cleaned location, count how many restaurants offer each of
italian,chinese,indian,mexican(one column per cuisine).
Output sorted by location_code ascending.