SHARE
TWEET

big boi

a guest Oct 21st, 2019 74 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import java.util.Scanner;
  2. class scratch_2 {
  3.     public static void main(String[] args) {
  4.         Scanner input = new Scanner(System.in);
  5.         System.out.println("Please enter a month number:");
  6.         int month = input.nextInt();
  7.         System.out.println("Input a year:");
  8.         int year = input.nextInt();
  9.         input.nextInt();
  10.         if(month == 1 && year == 2010)
  11.         {
  12.             System.out.println("January 2010 has 31 days");
  13.         }
  14.         else if(month == 2 && year == 2010)
  15.         {
  16.             System.out.println("February 2010 has 28 days");
  17.         }
  18.         else if(month == 3 && year == 2010)
  19.         {
  20.             System.out.println("March 2010 has 31 days");
  21.         }
  22.         else if(month == 4 && year == 2010)
  23.         {
  24.             System.out.println("April 2010 has 30 days");
  25.         }
  26.         else if(month == 5 && year == 2010)
  27.         {
  28.             System.out.println("May 2010 has 31 days");
  29.         }
  30.         else if(month == 6 && year == 2010)
  31.         {
  32.             System.out.println("June 2010 has 30 days");
  33.         }
  34.         else if(month == 7 && year == 2010)
  35.         {
  36.             System.out.println("July 2010 has 31 days");
  37.         }
  38.         else if(month == 8 && year == 2010)
  39.         {
  40.             System.out.println("August 2010 has 31 days");
  41.         }
  42.         else if(month == 9 && year == 2010)
  43.         {
  44.             System.out.println("September 2010 has 30 days");
  45.         }
  46.         else if(month == 10 && year == 2010)
  47.         {
  48.             System.out.println("October 2010 has 31 days");
  49.         }
  50.         else if(month == 11 && year == 2010)
  51.         {
  52.             System.out.println("November 2010 has 30 days");
  53.         }
  54.         else if(month == 12 && year == 2010)
  55.         {
  56.             System.out.println("December 2010 has 31 days");
  57.         }
  58.         else if(month == 1 && year == 2011)
  59.         {
  60.             System.out.println("January 2011 has 31 days");
  61.         }
  62.         else if(month == 2 && year == 2011)
  63.         {
  64.             System.out.println("February 2011 has 28 days");
  65.         }
  66.         else if(month == 3 && year == 2011)
  67.         {
  68.             System.out.println("March 2011 has 31 days");
  69.         }
  70.         else if(month == 4 && year == 2011)
  71.         {
  72.             System.out.println("April 2011 has 30 days");
  73.         }
  74.         else if(month == 5 && year == 2011)
  75.         {
  76.             System.out.println("May 2011 has 31 days");
  77.         }
  78.         else if(month == 6 && year == 2011)
  79.         {
  80.             System.out.println("June 2011 has 30 days");
  81.         }
  82.         else if(month == 7 && year == 2011)
  83.         {
  84.             System.out.println("July 2011 has 31 days");
  85.         }
  86.         else if(month == 8 && year == 2011)
  87.         {
  88.             System.out.println("August 2011 has 31 days");
  89.         }
  90.         else if(month == 9 && year == 2011)
  91.         {
  92.             System.out.println("September 2011 has 30 days");
  93.         }
  94.         else if(month == 10 && year == 2011)
  95.         {
  96.             System.out.println("October 2011 has 31 days");
  97.         }
  98.         else if(month == 11 && year == 2011)
  99.         {
  100.             System.out.println("November 2011 has 30 days");
  101.         }
  102.         else if(month == 12 && year == 2011)
  103.         {
  104.             System.out.println("December 2011 has 31 days");
  105.         }
  106.         else if(month == 1 && year == 2012)
  107.         {
  108.             System.out.println("January 2012 has 31 days");
  109.         }
  110.         else if(month == 2 && year == 2012)
  111.         {
  112.             System.out.println("February 2010 has 29 days");
  113.         }
  114.         else if(month == 3 && year == 2012)
  115.         {
  116.             System.out.println("March 2012 has 31 days");
  117.         }
  118.         else if(month == 4 && year == 2012)
  119.         {
  120.             System.out.println("April 2012 has 30 days");
  121.         }
  122.         else if(month == 5 && year == 2012)
  123.         {
  124.             System.out.println("May 2012 has 31 days");
  125.         }
  126.         else if(month == 6 && year == 2012)
  127.         {
  128.             System.out.println("June 2012 has 30 days");
  129.         }
  130.         else if(month == 7 && year == 2012)
  131.         {
  132.             System.out.println("July 2012 has 31 days");
  133.         }
  134.         else if(month == 8 && year == 2012)
  135.         {
  136.             System.out.println("August 2012 has 31 days");
  137.         }
  138.         else if(month == 9 && year == 2012)
  139.         {
  140.             System.out.println("September 2012 has 30 days");
  141.         }
  142.         else if(month == 10 && year == 2012)
  143.         {
  144.             System.out.println("October 2012 has 31 days");
  145.         }
  146.         else if(month == 11 && year == 2012)
  147.         {
  148.             System.out.println("November 2012 has 30 days");
  149.         }
  150.         else if(month == 12 && year == 2012)
  151.         {
  152.             System.out.println("December 2012 has 31 days");
  153.         }
  154.         else if(month == 1 && year == 2013)
  155.         {
  156.             System.out.println("January 2013 has 31 days");
  157.         }
  158.         else if(month == 2 && year == 2013)
  159.         {
  160.             System.out.println("February 2013 has 28 days");
  161.         }
  162.         else if(month == 3 && year == 2013)
  163.         {
  164.             System.out.println("March 2013 has 31 days");
  165.         }
  166.         else if(month == 4 && year == 2013)
  167.         {
  168.             System.out.println("April 2013 has 30 days");
  169.         }
  170.         else if(month == 5 && year == 2013)
  171.         {
  172.             System.out.println("May 2013 has 31 days");
  173.         }
  174.         else if(month == 6 && year == 2013)
  175.         {
  176.             System.out.println("June 2013 has 30 days");
  177.         }
  178.         else if(month == 7 && year == 2013)
  179.         {
  180.             System.out.println("July 2013 has 31 days");
  181.         }
  182.         else if(month == 8 && year == 2013)
  183.         {
  184.             System.out.println("August 2013 has 31 days");
  185.         }
  186.         else if(month == 9 && year == 2013)
  187.         {
  188.             System.out.println("September 2013 has 30 days");
  189.         }
  190.         else if(month == 10 && year == 2013)
  191.         {
  192.             System.out.println("October 2013 has 31 days");
  193.         }
  194.         else if(month == 11 && year == 2013)
  195.         {
  196.             System.out.println("November 2010 has 30 days");
  197.         }
  198.         else if(month == 12 && year == 2013)
  199.         {
  200.             System.out.println("December 2010 has 31 days");
  201.         }
  202.         else if(month == 1 && year == 2014)
  203.         {
  204.             System.out.println("January 2014 has 31 days");
  205.         }
  206.         else if(month == 2 && year == 2014)
  207.         {
  208.             System.out.println("February 2014 has 28 days");
  209.         }
  210.         else if(month == 3 && year == 2014)
  211.         {
  212.             System.out.println("March 2014 has 31 days");
  213.         }
  214.         else if(month == 4 && year == 2014)
  215.         {
  216.             System.out.println("April 2014 has 30 days");
  217.         }
  218.         else if(month == 5 && year == 2014)
  219.         {
  220.             System.out.println("May 2014 has 31 days");
  221.         }
  222.         else if(month == 6 && year == 2014)
  223.         {
  224.             System.out.println("June 2014 has 30 days");
  225.         }
  226.         else if(month == 7 && year == 2014)
  227.         {
  228.             System.out.println("July 2014 has 31 days");
  229.         }
  230.         else if(month == 8 && year == 2014)
  231.         {
  232.             System.out.println("August 2014 has 31 days");
  233.         }
  234.         else if(month == 9 && year == 2014)
  235.         {
  236.             System.out.println("September 2014 has 30 days");
  237.         }
  238.         else if(month == 10 && year == 2014)
  239.         {
  240.             System.out.println("October 2014 has 31 days");
  241.         }
  242.         else if(month == 11 && year == 2014)
  243.         {
  244.             System.out.println("November 2014 has 30 days");
  245.         }
  246.         else if(month == 12 && year == 2014)
  247.         {
  248.             System.out.println("December 2014 has 31 days");
  249.         }
  250.         if(month == 1 && year == 2015)
  251.         {
  252.             System.out.println("January 2015 has 31 days");
  253.         }
  254.         else if(month == 2 && year == 2015)
  255.         {
  256.             System.out.println("February 2015 has 28 days");
  257.         }
  258.         else if(month == 3 && year == 2015)
  259.         {
  260.             System.out.println("March 2015 has 31 days");
  261.         }
  262.         else if(month == 4 && year == 2015)
  263.         {
  264.             System.out.println("April 2015 has 30 days");
  265.         }
  266.         else if(month == 5 && year == 2015)
  267.         {
  268.             System.out.println("May 2015 has 31 days");
  269.         }
  270.         else if(month == 6 && year == 2015)
  271.         {
  272.             System.out.println("June 2015 has 30 days");
  273.         }
  274.         else if(month == 7 && year == 2015)
  275.         {
  276.             System.out.println("July 2015 has 31 days");
  277.         }
  278.         else if(month == 8 && year == 2015)
  279.         {
  280.             System.out.println("August 2015 has 31 days");
  281.         }
  282.         else if(month == 9 && year == 2015)
  283.         {
  284.             System.out.println("September 2015 has 30 days");
  285.         }
  286.         else if(month == 10 && year == 2015)
  287.         {
  288.             System.out.println("October 2015 has 31 days");
  289.         }
  290.         else if(month == 11 && year == 2015)
  291.         {
  292.             System.out.println("November 2015 has 30 days");
  293.         }
  294.         else if(month == 12 && year == 2015)
  295.         {
  296.             System.out.println("December 2015 has 31 days");
  297.         }
  298.     }
  299. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top