cseruhul

Problem 04

May 5th, 2021
538
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include<iostream>
  2. using namespace std;
  3.  
  4. void illustrate_department()
  5. {
  6.     int n;
  7.     cout << "Select a department:";
  8.     cout << "\n1 CSE\n2 EEE\n3 CE\n";
  9.     cin >> n;
  10.     switch(n)
  11.     {
  12.     case 1:
  13.         cout << "\n---(Computer Science and Engineering Department)---";
  14.         cout << "\n1 Structured Programming Language\n2 Structured Programming Language Sessional\n3 Introduction to Electrical Engineering\n4 Introduction to Electrical Engineering Sessional\n5 Differential Calculus and Coordinate Geometry\n6 Basic Mechanical Engineering\n7 Physics Sessional\n8 Physics (Heat and Thermodynamics, Structure of Matter, Waves and Oscillations,  and Physical Optics)\n10 Chemistry\n10 Inorganic Quantitative Analysis\n11 Discrete Mathematics\n12 Object Oriented Programming Language\n13 Object Oriented Programming Language Sessional\n14 Developing English Skills Sessional\n15 English\n16 Ordinary Differential Equations (ODE), Partialy Differential Equations (PDE) and Vector Calculus\n\n\n";
  15.         break;
  16.     case 2:
  17.         cout << "\n---(Electrical and Electronics Engineering Department)---";
  18.         cout << "\n1 Electrical Circuits I \n2 Electrical Circuits I Laboratory \n3 Electrical Circuits II \n4 Electrical Circuits II Laboratory \n5 Electronic Circuits I \n6 Electronic Circuits I Laboratory \n7 Energy Conversion \n8 Energy Conversion II \n9 Energy Conversion Laboratory \n10 Electronic Circuits II \n\n\n";
  19.         break;
  20.     case 3:cout << "\n---(Civil Engineering Department)---";
  21.         cout << "\n1 Analytical Mechanics\n2 Advanced\n3 Introduction to Civil Engineering \n4 Advanced Engineering Materials \n5 Basic Algebra, Matrices and Statistics \n6 Physics \n7 Physics Lab \n8 Numerical Methods & Programming \n9 Mechanics of Solids II \n10 Fluid Mechanics \n11 Differential Equations and Probability \n12 Engineering Materials Sessional \n13 Computer Programming Lab\n\n\n";
  22.         break;
  23.     }
  24. }
  25.  
  26.  
  27. void illustrate_courses()
  28. {
  29.     int n;
  30.     cout << "Select a Course:";
  31.     cout << "\n1 Structured Programming Language\n2 Introduction to Electrical Engineering\n3 Differential Calculus and Coordinate Geometry\n4 Basic Mechanical Engineering\n5 Physics\n6 Object Oriented Programming Language\n7 Electrical Circuits\n8 Energy Conversion\n9 Analytical Mechanics\n10 Fluid Mechanics\n11 English\n12 Social Science\n13 Accounting\n\n\n";
  32.     cin >> n;
  33.     switch(n)
  34.     {
  35.     case 1:
  36.         cout << "\n---(Structured Programming Language)---";
  37.         cout << "\n1 CSE\n\n\n";
  38.         break;
  39.     case 2:
  40.         cout << "\n---(Introduction to Electrical Engineering)---";
  41.         cout << "\n1 CSE\n2 EEE";
  42.         break;
  43.     case 3:cout << "\n---(Differential Calculus and Coordinate Geometry)---";
  44.         cout << "\n1 EEE\n2 CSE\n3 CE \n\n\n";
  45.         break;
  46.     case 4:cout << "\n---(Basic Mechanical Engineering)---";
  47.         cout << "\n1 CSE\n3 ME \n\n\n";
  48.         break;
  49.     case 5:cout << "\n---(Physics)---";
  50.         cout << "\n1 EEE\n2 CSE\n3 CE \n\n\n";
  51.         break;
  52.     case 6:cout << "\n---(Object Oriented Programming Language)---";
  53.         cout << "\n1 EEE\n2 CSE\n3 CE\n4 ME\n\n\n";
  54.         break;
  55.     case 7:cout << "\n---(Electrical Circuits)---";
  56.         cout << "\n1 EEE\n2 CSE\n3 CE \n\n\n";
  57.         break;
  58.     case 8:cout << "\n---(Differential Calculus and Coordinate Geometry)---";
  59.         cout << "\n1 EEE\n2 CSE\n\n\n";
  60.         break;
  61.     case 9:cout << "\n---(Energy Conversion)---";
  62.         cout << "\n1 EEE\n\n\n";
  63.         break;
  64.     case 10:cout << "\n---(Analytical Mechanics)---";
  65.         cout << "\n1 CE \n\n\n";
  66.         break;
  67.     case 11:cout << "\n---(Fluid Mechanics)---";
  68.         cout << "\n1 CE \n\n\n";
  69.         break;
  70.     case 12:cout << "\n---(English)---";
  71.         cout << "\n1 EEE\n2 CSE\n3 CE \n\n\n";
  72.         break;
  73.     case 13:cout << "\n---(Social Science)---";
  74.         cout << "\n1 EEE\n2 CSE\n3 CE \n\n\n";
  75.         break;
  76.     case 14:cout << "\n---(Accounting)---";
  77.         cout << "\n1 EEE\n2 CSE\n3 CE \n\n\n";
  78.         break;
  79.     }
  80. }
  81.  
  82. int main()
  83. {
  84.     int department, courses, n;
  85.     cout << "Please select one of the following(0 for exit): ";
  86.     cout << "\n1 Illustrate Department.\n2 Illustrate courses.\n3 press 0 to exit.\n";
  87.     cin >> n;
  88.  
  89.     while(n != 0)
  90.     {
  91.         switch(n)
  92.         {
  93.         case 1:
  94.             illustrate_department();
  95.             break;
  96.         case 2:
  97.             illustrate_courses();
  98.             break;
  99.         }
  100.  
  101.         cout << "Please select one of the following(0 for exit): ";
  102.         cout << "\n1 Illustrate Department.\n2 Illustrate courses.\n3 press 0 to exit.\n";
  103.         cin >> n;
  104.     }
  105.  
  106.  
  107.     return 0;
  108. }
  109.  
RAW Paste Data