我有两个字符串,如下所示:
String A = {"user1":{"cNo":4,"wId":1},"user2":{"cNo":5,"wId":1}}
String B = {"user1":{"cNo":4,"wId":1},"user3":{"cNo":6,"wId":1},"user2":{"cNo":5,"wId":1}}
我想构建一个新的 String C ,它不应包含任何重复项,如下所示(基于 user1 、 user2 、 user3 等值)
通常它应该如下所示,不包含任何重复项
String C = {"user1":{"cNo":4,"wId":1},"user3":{"cNo":6,"wId":1},"user2":{"cNo":5,"wId":1}}