Solucionado (ver solução)
Solucionado
(ver solução)
1
resposta

[Projeto] Resolução do desafio

#region #4 - Showing the singer's average
void SingerAverage()
{
    Console.Clear();
    ShowOptionsTitle("Singer's average");

    Console.Write("Please, enter with the singer's names: ");
    string singer = Console.ReadLine()!;
    if (singersList.ContainsKey(singer))
    {
        Double average = singersList[singer].Average();
        
        Console.Write($"\nThe singer's rating is {average}");
        Thread.Sleep(3000);
        Console.Clear();
        ShowMenu();
    }
    else
    {
        Console.WriteLine($"\nThe singer has not been registered, do you want to create?");
        Console.WriteLine($"\ny - yes and n - no");
        string choseOption = Console.ReadLine()!;

        if (choseOption == "y")
        {
            RegisterSongs();
        }
        else if (choseOption == "n")
        {
            ShowMenu();
        }
        else
        {
            ShowMenu();
        }
    }
}
#endregion
1 resposta
solução!

Retificando ...

#region #4 - Showing the singer's average
void SingerAverage()
{
    Console.Clear();
    ShowOptionsTitle("Singer's average");

    Console.Write("Please, enter with the singer's names: ");
    string singer = Console.ReadLine()!;
    if (singersList.ContainsKey(singer))
    {
        Double average = singersList[singer].Average();
        
        Console.Write($"\nThe singer's rating is {average}");
        Thread.Sleep(3000);
        Console.Clear();
        ShowMenu();
    }
    else
    {
        Console.WriteLine($"\nThe singer has not been registered, do you want to create?");
        Console.WriteLine($"\ny - yes and n - no");
        string choseOption = Console.ReadLine()!;

        if (choseOption == "y")
        {
            RegisterSingers();
        }
        else if (choseOption == "n")
        {
            ShowMenu();
        }
        else
        {
            ShowMenu();
        }
    }
}
#endregion