Arithmetic Flashcards
1
Q
last/2
A
54
2
Q
Arithmetic equality != Unification example. What does “=” mean?
A
55-56
3
Q
Semantics of the IS operator, preconditions
A
57-59
4
Q
What is the result of the query: A is +(*(3,2),4) ?
A
60
5
Q
len/2 without accumulator
A
61
6
Q
Explain why len/2 without acc requires O(N) stack space by using a search tree
A
62
7
Q
len/3 with an accumulator, show that it uses O(1) stack space.
A
63-64
8
Q
Last Call Optimisation conditions and transformation
A
65
9
Q
How would you validate if LCO is taking place
A
66