using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Programmation_objet_TLESIO21.TD3 { public class Compte { private int solde; public Compte() { this.solde = 0; } public void Deposer(int montant) { solde += montant; } public void Retirer(int montant) { solde -= montant; } public void VirerVers(int montant, Compte destination) { this.Retirer(montant); destination.Deposer(montant); } public override string ToString() { return ("Solde du compte = " + this.solde); } } }