Question: 1 ) ConferencesDemo 2 ) My code is running fine, but I cannot get grade yet. This are my ERRORS: Reason: Unable to run ConferencesDemo.cs

1) ConferencesDemo
2) My code is running fine, but I cannot get grade yet. This are my ERRORS:
Reason: Unable to run ConferencesDemo.cs
Unhandled Exception:
System.ArgumentNullException: Value cannot be null.
Parameter name: s
Please assist me.
using System;
using static System.Console;
using System.Globalization;
using System.Collections.Generic;
class Conference : IComparable
{
public string Group { get; set; }
public string Date { get; set; }
public int Attendees { get; set; }// least to greatest attendees
public int CompareTo(Conference other)
{
return Attendees.CompareTo(other.Attendees);
}
}
// NAME Conference starts on DATE and has ATTENDEES attendees
class ConferencesDemo // Conference
{
static void Main()// static
{
List conferences = new List();
for (int i =0; i 5; i++)//5 times
{
Conference conference = new Conference();
Write("Group: ");
conference.Group =ReadLine();
Write("Date: ");
conference.Date = ReadLine();
Write("Attendees: ");
conference.Attendees = int.Parse(ReadLine());
conferences.Add(conference);
}
conferences.Sort();
ReadLine();
foreach (var conference in conferences)
{
WriteLine($"{conference.Group} Conference starts on {conference.Date} and has {conference.Attendees} attendees");
}
}
}
 1) ConferencesDemo 2) My code is running fine, but I cannot

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!