using System;
public static class CalculPourcentage
{
public static decimal GetPorcentage(decimal valeur, decimal total)
{
return valeur / total * 100;
}
public static void Main(string[] argv)
{
Console.WriteLine("Pourcentage de 15 sur un total de 300= {0}%",GetPorcentage(15, 300));
}
}