This topic contains a solution. Click here to go to the answer

Author Question: The java.util.Calendar and java.util.GregorianCalendar classes are introduced in Chapter 11. Analyze ... (Read 70 times)

soccerdreamer_17

  • Hero Member
  • *****
  • Posts: 552

Question 1

Which of the following statements are correct?
◦ Object i = 4.5;
◦ Double i = 4.5;
◦ Number i = 4.5;
◦ Integer i = 4.5;

Question 2

The java.util.Calendar and java.util.GregorianCalendar classes are introduced in Chapter 11.
Analyze the following code.

1. import java.util.*;
2. public class Test {
3.public static void main(String[] args) {
4.Calendar[] calendars = new Calendar[10];
5.calendars[0] = new Calendar();
6.calendars[1] = new GregorianCalendar();
7.}
8. }

◦ The program has a compile error on Line 5 because java.util.Calendar is an abstract class.
◦ The program has a compile error on Line 6 because Calendar[1] is not of a GregorianCalendar type.
◦ The program has a compile error on Line 4 because java.util.Calendar is an abstract class.
◦ The program has no compile errors.


Related Topics

Need homework help now?

Ask unlimited questions for free

Ask a Question
Marked as best answer by soccerdreamer_17 on May 6, 2020

kaykay69

  • Sr. Member
  • ****
  • Posts: 322
Lorsum iprem. Lorsus sur ipci. Lorsem sur iprem. Lorsum sur ipdi, lorsem sur ipci. Lorsum sur iprium, valum sur ipci et, vala sur ipci. Lorsem sur ipci, lorsa sur iprem. Valus sur ipdi. Lorsus sur iprium nunc, valem sur iprium. Valem sur ipdi. Lorsa sur iprium. Lorsum sur iprium. Valem sur ipdi. Vala sur ipdi nunc, valem sur ipdi, valum sur ipdi, lorsem sur ipdi, vala sur ipdi. Valem sur iprem nunc, lorsa sur iprium. Valum sur ipdi et, lorsus sur ipci. Valem sur iprem. Valem sur ipci. Lorsa sur iprium. Lorsem sur ipci, valus sur iprem. Lorsem sur iprem nunc, valus sur iprium.
Answer Preview
Only 29% of students answer this correctly




soccerdreamer_17

  • Member
  • Posts: 552
Reply 2 on: May 6, 2020
:D TYSM


pratush dev

  • Member
  • Posts: 321
Reply 3 on: Yesterday
Wow, this really help

 

Did you know?

The types of cancer that alpha interferons are used to treat include hairy cell leukemia, melanoma, follicular non-Hodgkin's lymphoma, and AIDS-related Kaposi's sarcoma.

Did you know?

The immune system needs 9.5 hours of sleep in total darkness to recharge completely.

Did you know?

There are more sensory neurons in the tongue than in any other part of the body.

Did you know?

About 100 new prescription or over-the-counter drugs come into the U.S. market every year.

Did you know?

Russia has the highest death rate from cardiovascular disease followed by the Ukraine, Romania, Hungary, and Poland.

For a complete list of videos, visit our video library