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
gtnhenbr [62]
3 years ago
15

Which of the following class definition defines a legal abstract class Group of answer choices public class Rectangle abstract {

public abstract double findArea ( ); } public abstract class Rectangle { public abstract double findArea ( ); } public class Rectangle { public abstract double findArea ( ); } public class abstract Rectangle { public abstract double findArea ( ); }
Computers and Technology
1 answer:
valkas [14]3 years ago
7 0
<h2>Question</h2>

Which of the following class definition defines a legal abstract class Group of answer choices

(a)

public class Rectangle abstract {

   public abstract double findArea ( );

   

}

(b)

public abstract class Rectangle {

   public abstract double findArea ( );

   

}

(c)

public class Rectangle {

   public abstract double findArea ( );

   

}

(d)

public class abstract Rectangle {

   public abstract double findArea ( );

   

}

<h2>Answer:</h2>

(b)

public abstract class Rectangle {

   public abstract double findArea ( );

}

<h2>Explanation:</h2>

When a class is declared with the abstract keyword, the class is called an abstract class. Abstract classes cannot be instantiated and may include one or more abstract methods. If a class contains an abstract method, then it (the class) must be declared abstract.

In Java, abstract classes are defined using the following format:

<em>[access_modifier]</em> abstract class <em>[name_of_class]</em>

[access_modifier] specifies the access modifier of the class which could be public, private, e.t.c

abstract is the keyword that specifies that the class is an abstract class.

class is a keyword used for defining classes

name_of_class specifies the name of the class.

The only option that fulfils this format is <em>option b</em> where;

(i) The access modifier is public

(ii) The name of the class is Rectangle

Option a is not correct because the <em>abstract</em> keyword is supposed to come before the <em>class</em> keyword.

Option c is not correct because the keyword <em>abstract</em> is missing. In other words, the class must be declared abstract since it contains abstract method findArea();

Option d is not correct because the <em>abstract</em> keyword is supposed to come before the <em>class</em> keyword.

You might be interested in
What is the size of the key space if all 8 characters are randomly chosen 8-bit ascii characters?
Slav-nsk [51]
21...............................
4 0
3 years ago
Explain program and programming with two examples of each<br>Help​
evablogger [386]

Answer:

program (noun) is executable software that runs on a computer. ... Examples of programs include Web browsers, word processors, e-mail clients, video games, and system utilities. These programs are often called applications, which can be used synonymously with "software programs." On Windows, programs typically have an .

7 0
3 years ago
1) APPLICATION BASED QUESTION:-
schepotkina [342]

Answer:

Photoshop

Explanation:

8 0
2 years ago
8.6 Lesson Practice edhesive
scoundrel [369]

Incomplete question. I could only infer you are possibly referring to edhesive unit 8 questions. Here are a few sample questions;

1. Where does Python start?

2. To create the body of a function, we ____________ the code.

Answer:

1. Main Section

2. Indent

Explanation:

1. It is a common rule in Python programming language when coding for for it to begin at the first part of the Main Section.

2. Indenting a code involves creating space or jumping a line away from the margin of the text dialogue box, thus the code written there becomes the body of the function.

8 0
3 years ago
What do virtually all "phishing" emails have in common?
Arisa [49]
The name of your email/or dont have any name, asking for money, spelling mistakes, and sometimes a UNSUBSCRIBE button at the bottom of the email.
6 0
3 years ago
Other questions:
  • Alex leads a team of eight members. Arrange his tasks in sequential order of phases of group dynamics. What are the stages in gr
    13·1 answer
  • Using the syntax in section 2.3, write a command delete_all_rights (p, q, s). this command causes p to delete all rights the sub
    13·1 answer
  • What is the voltage drop across R4 in the diagram shown above?
    13·1 answer
  • You are the network administrator for a school system. Your boss informs you that she is thinking of implementing a BYOD program
    15·2 answers
  • Your mom wants to purchase a computer. She has heard about how the Windows 8 operating system is best-geared for a touch-enabled
    10·2 answers
  • A technician is configuring the Windows computers on a network to print to a printer that is directly connected to the network v
    8·1 answer
  • Choose the correct term to complete the sentence.
    15·2 answers
  • Why are free web based providers so popular?
    12·1 answer
  • The most common types of effects include entrances and exits
    11·1 answer
  • Write down the characterizations that best suits the term Java applets?
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!