Posts

MY IPAM GRADING SYSTEM PROGRAM

 import java.util.Scanner; public class IPAMGradeCalculator {     public static void main(String[] args) {         Scanner Med = new Scanner(System.in);         System.out.println("IPAM (USL) Grading System Calculator");         System.out.print("Enter student's score (0-100): ");         double score = Med.nextDouble(); if (score < 0 || score > 100) {             System.out.println("Invalid score! Please enter between 0-100.");         } else {             if (score >= 80) {                 System.out.println("A (Excellent)");             }                else if (score >= 70) {                 System.out.println("B+ (Very Good)");     ...

GRADE SYSTEM

 import java.util.Scanner; public class GradeCalculator {     public static void main(String[] args) {         Scanner Hafiz = new Scanner(System.in);         System.out.println("Enter marks for 3 core subjects:");         System.out.print("Computer Programming : ");         double DIT111 = Hafiz.nextDouble();         System.out.print("Mathematics for IT: ");         double DHM111 = Hafiz.nextDouble();         System.out.print("Communication skills: ");         double DCN112 = scanner.nextDouble();         double average = (DIT111 + DHM111 + DCN111) / 3; if (average >= 70) {             System.out.println("Grade: A");         } else if (average >= 60) {             System.out.println("Grade: B");     ...

EVEN OR ODD NUMBER CHECKER

 import java.util.Scanner; public class EvenOddChecker {     public static void main(String[] args) {         Scanner Med = new Scanner(System.in);         System.out.print("Enter a number: ");         int number = Med.nextInt();         if (number % 2 == 0) {             System.out.println(number + " is an even number.");         } else {             System.out.println(number + " is an odd number.");         }     } }

MONTH OF THE YEAR

 import java.util.Scanner; public class MonthOfYear {     public static void main(String[] args) {         Scanner Med = new Scanner(System.in);         System.out.println("Month of the Year Finder");         System.out.print("Enter a number (1-12): ");         int monthNumber = Med.nextInt();           String month;         switch (monthNumber) {             case 1:                 month = "January";                 break;             case 2:                 month = "February";                 break;             case 3:                 month = "March";  ...

DAY OF THE WEEK

 import java.util.Scanner; public class DayOfWeek {     public static void main(String[] args) {         Scanner Hafiz = new Scanner(System.in);                  System.out.println("Day of the Week Finder");         System.out.print("Enter a number (1-7): ");         int dayNumber = Hafiz.nextInt();         String day;         switch (dayNumber) {             case 1:                 day = "Monday";                 break;             case 2:                 day = "Tuesday";                 break;             case 3:                 day = "Wednesd...

LEAP YEAR CHECKER

  import java . util . Scanner ; public class LeapYearChecker { public static void main ( String [ ] args ) { Scanner scanner = new Scanner ( System . in ) ; System . out . println ( "Leap Year Checker" ) ; System . out . print ( "Enter a year: " ) ; int year = scanner . nextInt ( ) ; boolean isLeapYear = false ;           if ( year % 400 == 0 ) { isLeapYear = true ; } else if ( year % 100 == 0 ) { isLeapYear = false ; } else if ( year % 4 == 0 ) { isLeapYear = true ; } if ( isLeapYear ) { System . out . println ( year + " is a leap year." ) ; } else { System . out . println ( year + " is not a leap year." ) ; } } }

PLANE SHAPES AREA AND PERIMETER CALCULATOR

  import java.util.Scanner; public class AREA_CALCULATOR{ public static void main (String[] args) { Scanner Hafiz = new Scanner(System. in ); System. out .println( "WELCOME TO HAFIZ'S AREA CALCULATOR \n PRESS 1 FOR TRIANGLE \n PRESS 2 FOR CIRCLE" ); System. out .println( "PRESS 3 FOR RECTANGLE" ); System. out .println( "PRESS 4 FOR KITE" ); System. out .println( "PRESS 5 FOR TRAPEZIUM" ); System. out .println( "PRESS 6 FOR SQUARE" ); System. out .println( "PRESS 7 FOR RHOMBUS" ); System. out .println( "PRESS 8 FOR PARALLELOGRAM" ); System. out .print( "CHOOSE A SHAPE(1-8): " ); int choice = Hafiz.nextInt(); if (choice == 1 ) { System. out .println( "WELCOME TO THE TRIANGLE SECTION" ); System. out .print( "Enter (1) for Area , (2) for the Perimeter and (3) for both Area and P...