开发者社区 问答 正文

set集合方法intersection_update()的示例是什么?

set集合方法intersection_update()的示例是什么?

展开
收起
游客qzzytmszf3zhq 2021-11-04 21:23:00 305 分享 版权
1 条回答
写回答
取消 提交回答
  • set1 = {1,2,3} set2 = {3,4} set1.intersection_update(set2) set1 {3}

    2021-11-04 21:23:12
    赞同 展开评论