1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Georgia [21]
3 years ago
15

Assume that circle and objects are created as follows Circle circle = new Circle(1); GeometricObject object = new GeometricObjec

t(); a) Are the following Boolean expressions true or false? (circle instanceof GeometricObject) (object instanceof GeometricObject) (circle instanceof Circle) (object instanceof Circle) b. Can the following statements be compiled? Circle circle = new Circle(5); GeometricObject object = circle;
Computers and Technology
1 answer:
NARA [144]3 years ago
8 0

Answer and Explanation:

The output is false because Circle is used. Circle class has two methods, such as ( Circle circle ) and Object o that defined in the Object class. The Circle class inherits it. Circle.euqlais equaled to Object o because it is the type of circle1 and circle 2. The object of Circle is match circle1. equal by the compiler.

The output is accurate if Circle class overrides the equals to defined in Object class. The circle is matched to equals to object and run time method implemented in Circle class.

Both Circle has a different address. With Circle.equals(circle 2) replaced and have a same method in Object class.

Yes the following statement can be compiled the Circle circle = new Circle(5);

Geometric Object object = circle;

In this Object o is used to compile and run time as the circle has a different address. Method overriding allows dynamic binding, but it is always determined by declared type.

You might be interested in
Which of the following statements is NOT true regarding​ ERP? A. ERP promises​ slow, but​ accurate, information. B. ERP allows c
kkurt [141]

Answer:

A. ERP promises​ slow, but​ accurate information.

Explanation:

Option A. ERP promises slow, but accurate, information is incorrect. One of the most important aspects of Enterprise Resource Planning (ERP) has to do with time optimization through its "Automation" features which aim at cutting down several hours of staff work in performing tedious tasks. Accuracy in information is a must.

Among other important features and capabilities of ERP, it is worth mentioning:

1. Integration

2. Automation

3. Reporting

4. Tracking and Visibility

5. Data Analysis

6. Accounting

7. Customer Relationship Management

7 0
3 years ago
Read 2 more answers
How to move files and folders from desktop in w10?
Oksana_A [137]
Press CTRL + X to cut the file(s) and folder(s) you wish to move from your desktop.

Go to your destination (where you would like to move them to), and press CTRL + V to paste them there.
4 0
3 years ago
My mom hid my laptop and now I can't find it​
Svetach [21]

Answer: did you look everywhere ask for it and be like mom i wont do (whatever you did) ever again so please give me a chance can i plsss!!!!!! have it back?

Explanation:

simple as that step by step

3 0
3 years ago
The most direct way for Jonothan to gain on-the-jib experience and earn money while attending school is to apply for
Sholpan [36]
A part-time job would provide on-the-job experience while also giving him a flexible schedule competing with school.
4 0
3 years ago
Please describe the role of games in modern society!
ohaa [14]
It is to Entertainment.
5 0
3 years ago
Read 2 more answers
Other questions:
  • Why do computers need to periodically check the dns for websites you have already visited? enter your answer here?
    15·1 answer
  • Why is driving a privilege?
    15·2 answers
  • If you want an app to reach the largest possible audience, which two platforms should you use?
    7·1 answer
  • Which forensics tool would you use to reveal recent pages viewed via the internet explorer browser?
    10·1 answer
  • Which form of investigation aims at checking whether or not a target system is subject to attack based on a database of tests, s
    15·1 answer
  • PLEASE HELP ASAP!!!
    8·1 answer
  • Your task is to write a C program that measures the latencies of various system calls. In particular, you want to know 1) the co
    5·1 answer
  • Joann wants to insert page numbers at the bottom of the pages of her document using the Field option in Quick
    12·2 answers
  • Is it possible to have a deadlock involving only oneprocess? Explain your answer.
    11·1 answer
  • Which tool uses images and other visual elements to provide artistic
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!