← 返回题库
高级

综合:用户消费行为画像分析

未完成

示例

输入
solve()
期望输出
User behavior profiles:
  USR-0008: total=3040.3 avg=233.87 top_cat=CAT-09 pay=card manual=15.4%
  USR-0028: total=3710.27 avg=285.41 top_cat=CAT-09 pay=cash manual=0.0%
  USR-0018: total=3705.83 avg=308.82 top_cat=CAT-02 pay=card manual=16.7%
  USR-0026: total=2988.55 avg=249.05 top_cat=CAT-04 pay=alipay manual=25.0%
  USR-0019: total=2412.84 avg=219.35 top_cat=CAT-09 pay=wechat manual=45.5%
Python 代码 🔒 登录后使用
🔒

登录后即可练习

注册免费账号,在浏览器中直接运行 Python 代码