← 返回题库
中级

实现批量转账执行逐笔处理加结果收集

未完成
中级参考 代码结构已给出,请填写 ____ 处
def solve():
    from pyodide.http import open_url
    account_types_csv = open_url(____).read()
    payment_channels_csv = open_url(____).read()
    transfer_types_csv = open_url(____).read()
    transaction_limits_csv = open_url(____).read()
    accounts_csv = open_url(____).read()
    transfers_csv = open_url(____).read()
    fraud_rules_csv = open_url(____).read()
    items = [{'____': ____, '____': ____}, {'____': ____, '____': ____}, {'____': ____, '____': ____}]
    success, failed = ____, ____
    for item in items:
        if item['____'] > ____:
            print(____)
            success += ____
        else:
            print(____)
            failed += ____
    print(____)

示例

输入
solve()
期望输出
to_account_id=1  amount=15000.00  结果: SUCCESS
  to_account_id=2  amount=12000.00  结果: SUCCESS
  to_account_id=3  amount=18000.00  结果: SUCCESS
汇总: 成功3笔,失败0笔
Python 代码 🔒 登录后使用
🔒

登录后即可练习

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