Question: I have a lemma that says, if an integer i is a member of a singleton set s then s = { i }
I have a lemma that says, if an integer i is a member of a singleton set s then s i I write this lemma as follows:
lemma LemIAmSingles:set, i:int ensures s && i in s si
This generates an error because Dafny is not able to prove this property. Which of the following can be used as proof?
a
assert i in s s i
b
assert s && i in ss i
c
assert s i
d
if s assert i in s s i;
e
if s && i in s assert s i;
f
if s && i in s && s i assert true;
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
