Write a program (in pseudocode) for implementing an RSM using the Paxos algorithm.
If n is the number of commands issued by the client we need n instances of the Paxos algorithm.

Assume that at fictitious time t, two processes think that they are the distinguished process (i.e., proposer & learner). Discuss what happens to the system in terms of the safety and liveness requirements.
In the proposed case, the safety requirement is still maintained. However the liveness requirement is broken and the system may not reach consensus until only a single leader is elected. By maintaining property P2c the system is guaranteed to be safe even in this case, since different processes will never disagree on a chosen value.
Property P2c says: For any v and n, if a proposal (i.e., accept request) with value v and proposal number n is issued, then there is a set S comprised of a majority of acceptors such that either
However if the system has two distinct leaders, each is going to keep “flooding” the system with different proposals preventing normal operation. This happens because new values may never be agreed on, until only one leader is elected.