Good day gentlement and ladies. I need help concerning how to build a menu for selecting from a list of choices. let's say for example that I want the user to select to a minimum of 4 choices,if they only want two the should select 2 and press a certain key to move on to the next phase of my program. What code should i write or pseudocode do you suggest for this operation? I am thinking of using a case Switch statement embedded in a For Loop. is this assumption Correct? Thank you for your time and attention.
here is the code I am working on so far:
using system;
namespace Student_application{
class student {
private string first_name,last_name;
private int age,Year_of_Birth;
public student(){
string first_name;
string last_name;
int age;
int Year_of_Birth;
}
// public method in student class to get student information
public void getstudentinfo()
{
Console.Writeline("What is your name,age,year of birth?");
first_name=Console.Readline();
last_name=Console.Readline();
age=ConvertToInt32(Console.ReadLine());
Year_of_Birth=ConvertToInt32(Console.ReadLine());
}
}
// Demonstration of class inheritance by course being a derived class of student
// public method to input courses
class Course:student{
private string course1,course2,course3,course4;
private int Number_of_Courses;
public Course(){
int Number_of_Courses[];
}
public Course_modify(){
get{ return Number_of_Courses;}
set{ Number_of_Courses=value;}
}
public void Course_selection(){
Console.Writeline(" Welcome",{0} {1} first_name,last_name);
Console.Writeline("Input a minimum of 4 courses you wish to pursue for this semester. press x when you are finished with your selection.")
Number_of_Courses=ConvertToInt32(Console.ReadLine());
course1=Console.Readline();
course2=Console.Readline();
course3=Console.Readline();
course4=Console.Readline();
}
}
class fee_details:Course{
private const double course_cost=500.34;
private const double exam_fee=230.34;
private const double library_fee=110.12;
if
}