Answer to Question #255555 in Java | JSP | JSF for Aji

Question #255555
Write a program to find the counseling slot based on the student's Cutoff marks, age, HSC and SSLC marks
1
Expert's answer
2021-10-24T00:40:02-0400


SOLUTION CODE FOR ABOVE QUESTION


/*
This program is written to divide the students into four counselling slots
 */
package com.company;

import java.util.*;

public class Main {

    public static void main(String[] args) {
   // write your code here
        Scanner sc = new Scanner(System.in);
        System.out.println("\nHello welcome to our program, enter the students details," +
                "\nto know the slot which the student belongs to");
        System.out.print("\nEnter the students cut off marks: ");
        int cut_of_marks = sc.nextInt();
        System.out.print("Enter the students age: ");
        int age  = sc.nextInt();
        System.out.print("Enter the HSC mark: ");
        int hsc  = sc.nextInt();
        System.out.print("Enter the students Secondary Level School Certificate(SSLC) Mark: ");
        int sslc  = sc.nextInt();
        if(age > 18 & cut_of_marks > 79 & hsc > 79 & sslc > 79)
        {
            System.out.println("\nThe student belongs to  1st Slot of Counseling");
        }
        else if(age > 18 & cut_of_marks > 69 & hsc > 69 & sslc > 69)
        {
            System.out.println("\nThe student belongs to 2st Slot of Counseling");
        }
        else if(age > 18 & cut_of_marks > 50& hsc > 50 & sslc > 50)
        {
            System.out.println("\nThe student belongs to  3rd Slot Counseling");
        }
        else
        {
            System.out.println("\nThe student belongs to  4rd Slot Counseling");
        }
    }
}



SAMPLE PROGRAM OUTPUT






Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS