Given two dictionaries A and B: –Find all keys in A and B that have different values, or only in one dictionary but not the other
1 回答
![?](http://img1.sycdn.imooc.com/533e4ca50001117901990200-100-100.jpg)
pardon110
TA贡献1038条经验 获得超227个赞
分明就是一个python集合的补集运算,先将字典A或B的值视图取出,转为各自的集合类型 然后进行^补集运算(又称对称差集),就可得到结果了。
添加回答
举报
0/150
提交
取消