Exercice3: done with snapshots