✅ The verified answer to this question is available below. Our community-reviewed solutions help you understand the material better.
Considérons l'algorithme suivant. Parmi les propositions suivantes, laquelle est vraie ?
Algorithm : algo1
Variables :
s, r : string (* on suppose que length(s) <= length(r) *)
p : string
i : integer
Begin
Read(s)
Read(r)
p <- ∅
While i <= length(s) AND s[i] = r[i] Do
p <- p + s[i]
i <- i + 1
End while
Write(p)
End