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 ( ); }

Answers

Answer 1
Question

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 ( );

   

}

Answer:

(b)

public abstract class Rectangle {

   public abstract double findArea ( );

}

Explanation:

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:

[access_modifier] abstract class [name_of_class]

[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 option b where;

(i) The access modifier is public

(ii) The name of the class is Rectangle

Option a is not correct because the abstract keyword is supposed to come before the class keyword.

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

Option d is not correct because the abstract keyword is supposed to come before the class keyword.


Related Questions

Write a class called AddThreeGame that allows two players to play a game in which they alternately choose numbers from 1-9.

Answers

Answer:

Explanation:

The following code is written in Python, it creates the AddThreeGame as requested for 2 players. Outputting the desired output after each player has chosen a number and checking for a winner after every choice. Due to technical reasons, I had to add the code as a txt file below and the output can be seen in the attached picture.

Define a method calcPyramidVolume with double data type parameters baseLength, baseWidth, and pyramidHeight, that returns as a double the volume of a pyramid with a rectangular base. calcPyramidVolume() calls the given calcBaseArea() method in the calculation.

Answers

Answer:

The method in C++ is as follows:

double calcPyramidVolume(double baseLength, double baseWidth, double pyramidHeight){

   double baseArea = calcBaseArea(baseLength, baseWidth);

   double volume = baseArea * pyramidHeight;

   return volume;    

}

Explanation:

This defines the calcPyramidVolume method

double calcPyramidVolume(double baseLength, double baseWidth, double pyramidHeight){

This calls the calcBaseArea method to calculate the base area of the pyramid

   double baseArea = calcBaseArea(baseLength, baseWidth);

This calculates the volume

   double volume = baseArea * pyramidHeight;

This returns the volume

   return volume;  

}

See attachment for complete program that include all methods that is required for the program to function.

(b) Write a program which displays the following pattern as an output.
*
**
***
****
*****
(Hint: using loop)

Answers

this is the answer for your question i´m guessing i hope this helped :)

******

which data type uses %i as a format specifier​

Answers

Answer:

A decimal integer

Explanation:

Hope this helps!

write a program to input 100 students marks and find the highest marks among the them​

Answers

Answer:

Explanation:

The following code is a Python program that allows you to input 100 marks. You can input the value -1 to exit the loop early. Once all the marks are entered the program prints out the highest mark among all of them. The output can be seen in the attached picture below with a test of a couple of marks.

marks = []

for x in range(100):

   mark = int(input("Enter a mark: "))

   if mark == -1:

       break

   else:

       marks.append(mark)

print("Max value: " + str(max(marks)))

Match each code snippet to its appropriate markup language name. XML CSS HTML XHTML


Answers

Answer:

Please find the complete solution in the attached file.

Explanation:

answer:

<p>line break</p><br/>  : XHTML

<Address>24, North Block</Address> : XML

<P>New paragraph</P> : HTML

<h2 style=“color:red;font-size:12px;”>Heading in red color.</h2> : CSS

just truuust

Justin Kace is promoting the metric system and wants people to be able to convert miles to kilometers and kilometers to miles. Develop a program that asks the user for a number of miles and converts miles to kilometers (multiplying miles by 1.609), and then asks for a number of kilometers and converts kilometers to miles (multiplying kilometers by 0.6214).

Answers

Solution :

//Program heading

Display "Kilometers to [tex]$\text{Miles}$[/tex] and [tex]$\text{Miles}$[/tex] to Kilometers Conversion Program"

//Get [tex]$\text{Miles}$[/tex]

Display "Enter the [tex]$\text{miles}$[/tex]: "

Input [tex]$\text{miles}$[/tex]

//Convert [tex]$\text{miles}$[/tex] to kilometers and display result

converted_km =[tex]$\text{miles}$[/tex] x 1.609

Display "Converted kilometers = " + converted_km

//Get Kilometers

Display "Enter the kilometers: "

Input km

 

//Convert kilometers to [tex]$\text{miles}$[/tex] and display result

converted_[tex]$\text{miles}$[/tex] = km x 0.6214

Display "Converted [tex]$\text{miles}$[/tex] = " + converted_[tex]$\text{miles}$[/tex]

//Thank the user for using this program

Display "Thank you for using this program. Good-bye!"

Stop

Sample Output:

Kilometers to [tex]$\text{Miles}$[/tex] and [tex]$\text{Miles}$[/tex] to Kilometers Conversion Program

Enter the [tex]$\text{miles}$[/tex]: 10

Converted kilometers = 16.09

Enter the kilometers: 10

Converted [tex]$\text{miles}$[/tex] = 6.214

Thank you for using this program. Good-bye!

1. Which of the following is a new
generation optical storage device?
CD
DVD
Blu-ray disc
Pen drive

Answers

Answer:

CD or CD Rom

fhiykkoojnddeyui

6.What does transgenic mean?​

Answers

answer:

transgenic means that one or more DNA sequences from another species have been introduced by artificial means.

explanation:

transgenic plants can be made by introducing foreign DNA into a variety of different tissuestransgenic mice are one of the most common animal models used

relating to or denoting an organism that contains genetic material into which DNA from an unrelated organism has been artificially introduced. being or used to produce an organism or cell of one species into which one or more genes of another species have been incorporated a transgenic mouse transgenic crops and produced by or consisting of transgenic plants or animals.

In this code, there's a Person class that has an attribute name, which gets set when constructing the object. Fill in the blanks so that 1) when an instance of the class is created, the attribute gets set correctly, and 2) when the greeting() method is called, the greeting states the assigned name. mtino 1-class Person: 2 - def __init__(self, name): self.name = def greeting(self): # Should return "hi, my name is " followed by the name of the Person. return Run 8 # Create a new instance with a name of your choice 9 some_person = 10 # Call the greeting method 11 print (some_person. ) 12 Press ESC to exit the code block at any time

Answers

Answer:

Explanation:

The following code is written in Python. It creates a Person class and creates the constructor which takes in the name of the person for that instance, as well as a greeting method which outputs the desired "Hi, my name is" string with the name of that person. The output of the code can be seen in the attached picture below. I have created a person object called John and called the greeting method so that you can see the output.

class Person:

   name = ''

   def __init__(self, name):

       self.name = name

   def greeting(self):

       print('Hi, my name is ' + self.name)

The code containing the Person class definition and the greeting is found in the attached image

The Person class has a single instance field name that stores the name of the person.

The instance initializer, __init__, accepts an argument, name, and saves the value in the name attribute of the Person class.

The Person class also has a greeting method that is called by the main code segment. The main code segment creates a Person object, and calls it in the print function to display the greeting with the person's name.

Learn more about classes in Python here https://brainly.com/question/21065208

Assignment: Provide a reflection paper of 500 words minimum (2 pages double spaced) of how the knowledge, skills, or theories of Risk Management and Information Security have been applied, or could be applied, in a practical manner to your current work environment. If you are not currently working, share times when you have or could observe these theories and knowledge could be applied to an employment opportunity in your field of study.Requirements: Provide a 500 word (or 2 pages double spaced) minimum reflection. Use of proper APA formatting and citations. If supporting evidence from outside resources is used those must be properly cited. Share a personal connection that identifies specific knowledge and theories from this course. Demonstrate a connection to your current work environment. If you are not employed, demonstrate a connection to your desired work environment. You should NOT provide an overview of the assignments assigned in the course. The assignment asks that you reflect how the knowledge and skills obtained through meeting course objectives were applied or could be applied in the workplace.

Answers

Answer:

Following are the response to the given question:

Explanation:

They are already talking business to business collects in which we are calling the client for collecting whenever the products which we have purchased are overdue and overdue inside 30 days. About business criteria, we should ensure no other websites mostly on agent acting open up so that nobody can misuse it; we also have to know the correct revising and trying to run off all systems and therefore all apps are organ systems because then the critical business work time has would not get out of the way. This is about the security of information. The agents also are adequately taught in IT policy according to the demand of the company.

They soon come towards the area of risk, experience, and skill. All agents ought to have proper refresh sessions to fulfill GAP knowledge but also improve their abilities for 100 percent cent accuracy on TAT on every appeal. Your Agency's response.

There ought to be a right party connect. We must keep up with 80-20 RULE which means that we can easily acquire the bigger amount earlier than somehow investing whatever money for future production if we concentrate on TOP 20 Overdue Current Passengers.

When we add up the current sum owing as well as the amount due by both the end of the month, so we will subtract all promises that were made by the end of each month. You can readily deduce how long and how much money will be received by the end of each month, and how long this will be due by the end of each month.

The total danger which we imagine to be cash flow issues is when a company is close to collapse or even has a money problem, they are few risks that any company has.

To solve this RISK to money flow clients, we have to provide them a payment plan so that we could at the very least invest some cash in additional production. Besides offering customers a pay system, you truly cannot help.

Another key potential risk is the unrequired quantity on the accounts of the consumer. Underneath the U.S. government, it'll be a direct responsibility of the government if there is an unclear and unapplied amount which has lied to an account for even more than 4 years.

Therefore it does have to do about risk, skills, knowledge the safety of information. All above theory helps explain everything which enables the execution of operations as well as, as project manager, we have to track input and output information. we need to charge, past due, credits, debits, PD percent every week and month, seeing the company's pattern, and also transform policies as to how the trend or even the forecast can enhance.

LaToya is creating a program that will teach young children to type. What keyword should be used to create a loop that will print “try again” until the correct letter is typed
a. print

b. random

c. else

d. while

Answers

Question:

LaToya is creating a program that will teach young children to type. What keyword should be used to create a loop that will print “try again” until the correct letter is typed

Answer:

d. while ✓

Explanation:

The while loop is used to repeat a section of code an unknown number of times until a specific condition is met.

[tex] \\ \\ [/tex]

Hope it helps

-------☆゚.・。゚ᵴɒƙυᴚᴀ_ƨȶäᴎ❀

What is the difference between autofocus and autocomplete

Answers

Answer:

https://www.c-sharpcorner.com/interview-question/explain-autofocus-and-autocomplete-attribute

found this on a website hope you find it useful !

Which is the best definition of manageable?
A. asking for help from others
B. making a plan
C. breaking down a big goal into smaller pieces
D. creating multiple goals

Answers

Answer:

D. Creating mutiple goals.

Explanation:

The length of a list can be determined through the index function

True

False

Answers

Answer:

false

Explanation:

User account
2. The system allows user to register and create the account
3. Users allowed by system to edit & modify the account
4. System allows users to view products
5. System allows users to comment on product
6. Perform sentiment analysis
7. Use APS to connect to product
8. Review website to collect comment of product
9. System dynamically analyze command of users
10. Matching keyword in database
11. system allots rank to product as good, bad and ugly
12. view product review
13. users can use system to view product
14. manage users account
15. all users account allowed to be added or modified , and deleted by administrator


Non Functional Requirements:

1. Efficiency

2. Interoperable

3. Portability

4. Security

Part A: Answer the following questions prefer to the previous requirements?

Question :

Three Use-Case Narrative. Choose one major use-case for each player (Customer, Shop Owner, and Administrator).

Answers

Numa máquina térmica uma parte da energia térmica fornecida ao sistema(Q1) é transformada em trabalho mecânico (τ) e o restante (Q2) é dissipado, perdido para o ambiente.



sendo:

τ: trabalho realizado (J) [Joule]
Q1: energia fornecida (J)
Q2: energia dissipada (J)


temos: τ = Q1 - Q2

O rendimento (η) é a razão do trabalho realizado pela energia fornecida:

η= τ/Q1

Exercícior resolvido:
Uma máquina térmica cíclica recebe 5000 J de calor de uma fonte quente e realiza trabalho de 3500 J. Calcule o rendimento dessa máquina térmica.

solução:

τ=3500 J
Q1=5000J

η= τ/Q1
η= 3500/5000
η= 0,7 ou seja 70%

Energia dissipada será:



τ = Q1 - Q2
Q2 = Q1- τ

Q2=5000-3500
Q2= 1500 J

Exercicio: Qual seria o rendimento se a máquina do exercicio anterior realizasse 4000J de trabalho com a mesma quantidade de calor fornecida ? Quanta energia seria dissipada agora?



obs: Entregar foto da resolução ou o cálculo passo a passo na mensagem

1. ¿Qué es un cursograma?

Answers

Answer:

Un cursograma permite representar gráficamente procedimientos administrativos. Constituyen instrumentos importantes para la visualización global y esquemática del conjunto de tareas administrativas.

Un cursograma permite representar gráficamente procedimientos administrativos. Constituyen instrumentos importantes para la visualización global y esquemática del conjunto de tareas administrativas.

Ojalá te ayude !:)

Create a new Java program called Flip. Write code that creates and populates an array of size 25 with random numbers between 1-50. Print the original array. Print array in reverse.

Answers

Use the website code .org to help you

Declare a typedef struct named jumper_t that will have four parts: character array name that is 16 in length, double array of tries that is N_TRIES in length, double best_jump, double deviation 2. Write one line to declare an array variable, named jlist of the above struct type, with a length of ten. No initialization required.

Answers

Answer:

The typedef struct is as follows:

typedef struct jumper_t {

  char name[16];

  double tries[N_TRIES];

  double best_jump;

  double deviation;

} jumper_t;

The declaration of jlist is:

jumper_t jlist[10];

Explanation:

This defines  the typedef structure

typedef struct jumper_t {

The following declares the variables as stated in the question

  char name[16];

  double tries[N_TRIES];

  double best_jump;

  double deviation;

}

This ends the typedef definition

jumper_t;

(b) The declaration of array jlist is:

jumper_t jlist[10];

Question # 4
Fill in the Blank
Complete the following sentence.
The first email was sent in
.

Answers

Answer:

1971

Explanation:

If there is more detail needed i'm sorry

Answer:

1971

Explanation:

#Nova

Have a great day!

:)

They need network security skills to know how to perform tasks such as:

A. Testing software before launching.
B. maintaining databases.
C. investigating virus attacks​

Answers

B) maintaining databases

Answer:

Your answer should be C

because in they will protect the data base from virus.

In this lab, you complete a C++ program that swaps values stored in three int variables and determines maximum and minimum values. The C++ file provided for this lab contains the necessary variable declarations, as well as the input and output statements. You want to end up with the smallest value stored in the variable named first and the largest value stored in the variable named third. You need to write the statements that compare the values and swap them if appropriate. Comments included in the code tell you where to write your statements.InstructionsEnsure the Swap.cpp file is open in your editor.Write the statements that test the first two integers, and swap them if necessary.Write the statements that test the second and third integer, and swap them if necessary.Write the statements that test the first and second integers again, and swap them if necessary.Execute the program by clicking the "Run Code" button at the bottom of the screen using the following sets of input values.101 22 -23630 1500 921 2 2Provided code:// Swap.cpp - This program determines the minimum and maximum of three values input by// the user and performs necessary swaps.// Input: Three int values.// Output: The numbers in numerical order.#include using namespace std;int main(){ // Declare variables int first = 0; // First number int second = 0; // Second number int third = 0; // Third number int temp; // Used to swap numbers const string SENTINEL = "done"; // Named constant for sentinel value string repeat; bool notDone = true; //loop control // Get user input cout << "Enter first number: "; cin >> first; cout << "Enter second number: "; cin >> second; cout << "Enter third number: "; cin >> third; while(notDone == true){ // Test to see if the first number is greater than the second number // Test to see if the second number is greater than the third number // Test to see if the first number is greater than the second number again // Print numbers in numerical order cout << "Smallest: " << first << endl; cout << "Next smallest: " << second << endl; cout << "Largest: " << third << endl; cout << "Enter any letter to continue or done to quit: "; cin >> repeat; if (repeat == SENTINEL){ notDone = false; } else { cout << "Enter first number: "; cin >> first; cout << "Enter second number: "; cin >> second; cout << "Enter third number: "; cin >> third; } return 0;} // End of main function

Answers

Answer:

Following are the code to the given question:

#include <iostream>//header file

using namespace std;

int main()//main method

{

int first = 0,second = 0,third = 0;//defining integer variable  

int temp; //defining integer variable

const string SENTINEL = "done"; // defining a string variable as constant  

string repeat;// defining a string variable  

bool notDone = true; //defining bool variable

cout << "Enter first number: ";//print message

cin >> first;//input value

cout << "Enter second number: ";//print message

cin >> second;//input value

cout << "Enter third number: ";//print message

cin >> third;//input value

while(notDone == true)//defining a loop to check the value  

{

if(first > second)//use if to compare first and second value

{

int temp = first;//defining temp to hold first value

first = second;//holding second value in first variable

second = temp;//holding temp value in second variable

}

if(second > third)//use if to compare second and third value

{

int temp = second;//defining temp to hold second value

second = third;//holding second value in third variable

third = temp;//holding temp value in third variable

}

cout << "Smallest: " << first << endl;//print smallest value

cout << "Next smallest: " << second << endl;//print Next smallest value

cout << "Largest: " << third << endl;////print Largest value

cout << "Enter any letter to continue or done to quit: ";//print message

cin >> repeat;//holding string value

if (repeat == SENTINEL)

{

notDone = false;//holding bool value

}  

else //else block

{

cout << "Enter first number: ";//print message

cin >> first;//input value

cout << "Enter second number: ";//print message

cin >> second;//input value

cout << "Enter third number: ";//print message

cin >> third;//input value

}

return 0;

}

}

Output:

Please find the attached file.

Explanation:

Inside the main method Four integer variable "first, second, third, and temp" is declared in which first three variable is used for input value and temp is used to compare value. In thew next step, two string variable "SENTINEL and repeat" is declared in which "SENTINEL" is constant and a bool variable "notDone" is declared. After input the value from the user-end a loop is declared that compare and swap value and print its value.

Which measurement symbol is this?
PLS HELP

Answers

Answer:

Foot.

Explanation:

Hope this helps!

In theory, a hacker with a small but powerful directional antenna could access a wireless network from more than one mile away. In a real-world situation, what is the more likely range involved

Answers

100 miles i assume since the avarge antanna cover 5-50 miles

Sam plans to use this image in artwork for a brochure about airplanes. Which principles of page layout is Sam planning to use in this artwork?

A. emphasis
B. repetition
C. balance
D. alignment
E. proximity

Answers

Answer: Alignment

Explanation:

The principle of repitition indicates that some aspect of a design are repeated. This can be in form of bullet list, lines, color etc.

Balance has to do with how the weight is distributed.

The Principle of Alignment means that the pictures on a page should be connected visually to another thing.

Principle of Proximity simoly means that the items that are related on a page should be close to each other.

Therefore, the principles of page layout that Sam is planning to use in this artwork is alignment.

Answer:

D. alignment

Explanation:

How to open an image by using the command prompt? I need the explanation step by step. Please Help.

Answers

Open a file from Windows Terminal

In a command prompt window, type cd followed by the path of the file that you wish to open. After the path matches with the one in the search result. Enter the file name of the file and press Enter. It will launch the file instantly.

A virus that loads itself onto the target system's memory, infects other files, and then unloads itself is called a:

Answers

Answer:

True. A virus that loads itself onto the target system's memory, infects other files, and then unloads itself is called a: Direct-action virus.

Explanation:

A virus that loads itself onto the target system's memory, infects other files, and then unloads itself is called a Direct-action virus.

What is Direct-action virus?

A direct action computer virus is known to be a virus class that is said to be self-multiplying malware that is known to be attached to any executable file.

Therefore, Note that A virus that loads itself onto the target system's memory, infects other files, and then unloads itself is called a Direct-action virus.

Learn more about virus from

https://brainly.com/question/26128220

#SPJ2

Please help it’s timed

Answers

Answer:

you are proooooooooooooooooooo

Explanation:

Write a program to sort the (name, age, score) tuples by descending order where name is string, age and score are numbers. The sort criteria is: 1: Sort based on name 2: Then sort based on age 3: Then sort by score The priority is that name < age < score. If the following tuples are given as input to the program: [('John', '20', '91'), ('Jason', '21', '85'), ('Jony', '17', '91'), ('Johny', '17', '93'), ('Tom', '19', '80')]\

Answers

Answer:

The program in Python is as follows:

from operator import itemgetter

m = int(input("Number of records: "))

print("Name, Age, Score")

my_list =[]

for i in range(m):

   user_details = input()

   my_list.append(tuple((user_details.split(","))))

my_list.sort(key =  itemgetter(0, 1, 2))        

print("Sorted: ", my_list)

Explanation:

This imports the operator function from itemgetter

from operator import itemgetter

This gets the number of records, m

m = int(input("Number of records: "))

This prints the format of input

print("Name, Age, Score")

This initializes the list of tuples

my_list =[]

This iterates through m

for i in range(m):

This gets the details of each person

   user_details = input()

This appends the details to the tuple

   my_list.append(tuple((user_details.split(","))))

This sorts the tuple

my_list.sort(key =  itemgetter(0, 1, 2))        

This prints the sorted tuple

print("Sorted: ", my_list)

. Write the advantages and disadvantages of CLI?

Answers

If you know the commands, a CLI can be a lot faster and efficient than any other type of interface. ...A CLI requires less memory to use in comparison to other interfaces. ...A CLI doesn't require Windows and a low-resolution monitor can be used
Other Questions
A more electronegative atom A) will have more attraction to the electrons in a chemical bond. B) is more likely to lose an electron. C) is less likely to form a chemical bond. D) is more likely to form an ionic bond with another highly electronegative atom. PLEASE HELP FASTNO LINKS OR TROLL ANSWERS I WILL REP0RT Let f(x) = cos(x) + 2x.Where does f have critical points? Which best describes the relationship betweencharacter and conflict in the excerpt? Whats the right one ? Explain the significance of Mahatmas Gandhi to the Indian independence movement? Mr. Johnson buys 5 bottles of lemonade for the school plenie, He buys four 28-ounce bottles and one 64 ounce bottle. Using rounding to the nearest ten, abouthow much lemonade does Mr. Johnson buy in all? Which of the following exponential functions represents the graph below =-= 50 Points =-= Must give the correct answerSolve by equating exponents and using the Equality of Bases Property. Solve (2)^x/2 = 16 for x please help! i will give brainliest if you answer all and correctly Please Help!Which equipment is used to warm up before a workout?A. le tapis roulantB. lhaltreC. lappareil dtirementD. les poids A delivery driver estimates his truck uses an averageof 22.5 gal of fuel per day. This estimate is within 4%of the actual fuel the driver records each day for onemonth HELPP HELPPP ????pls New voice English text book a day answer Tad runs one-half mile for every one-third mile thatElaine runs. If together they run a total of 10 miles, howfar does Tad run? Explain why Jesus message was appealing to the people of Rome. Kirk ran 7 1/2 miles around the track. Each lap is 2 1/2 miles. How many laps did Kirk run?Write your answer as a fraction or as a whole or mixed number. Which type of loaded language is used in the image below?Question 7 options:StereotypeParallelismRepetitionLoaded Language Which statement explains why the structure of sickle cells differs from normal red blood cells? a. The gene mutation affected protein synthesis. b. The gene mutation prohibited DNA replication. c. The gene mutation inhibited the cell's ability to produce tRNA. d. The gene mutation affected the cell's ability to produce ATP. im think its A or C. help :(