Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我写了类似的东西
requires notBool(K |-> V in P)
但这似乎不是正确的语法。检查映射中是否不存在键值对的正确方法是什么?
您想要的语法是notBool K in_keys(P)检查键是否在地图中。如果你还想检查键是否绑定到某个值,你可以写notBool K in_keys(P) orBool P[K] =/=K V.
notBool K in_keys(P)
notBool K in_keys(P) orBool P[K] =/=K V