Question 1 In this question, you need to create an interface and an abstract class. For the interface, name it ShapeInterface and create the following methods: • An abstract method named calsarea that returns a douhle
Q: Write a program that asks the user for a word, then prints out the word once on the first line, twic...
A: Please refer to the following steps for the complete solution to the problem above.
Q: WHAT IS CRYPTOCURRENCY AND HOW DOES IT WORK?
A: NOTE Below is the answer for the given question. Hope you understand it well. If you have any doubts...
Q: BUSINESSES AND ORGANIZATIONS HAVE BEEN TOLD THAT BLOCKCHAIN TECHNOLOGY HAS POTENTIAL, BUT WHY?
A: Introduction: Following the internet's inception, cryptocurrencies and the underlying blockchain tec...
Q: You are given 4 items as (ralue, veightpairs in this format {{20, 5},{60, 20}, {25, 10}, {X, 25}}You...
A: 1. Given {{20.5},{60,20},{25,10},{X,25}} Capacity of knapsack = 50 Since the items are in sorted or...
Q: Why is encryption still viewed as the primary means of preventing data loss?
A: Introduction: Data loss prevention (DLP) is a collection of technologies and processes designed to k...
Q: dd a new public member function to the LinkedList class named reverse() which reverses the items in ...
A: given program below
Q: If the file 'source.txt' contains a line "Be my friend" which of the following will be the output of...
A: FILE *fs, *ft; two file pointer declared char c[10]; means a string "c" stores 10 characters fs...
Q: iv) Define a Python function that takes an integer n as the parameter and returns true if n is in th...
A: Define a Python function that takes an integer n as the parameter and returns True if n is in the ra...
Q: Create an application on C# that has two methods. The first one calculates the area of a rectangle. ...
A: The program is in next step -
Q: Name the three levels in the 3-level DB architecture.
A:
Q: I'd like to send in a PowerPoint presentation to have the APA citations and references checked again...
A: Introduction: Include the name of the author (whoever presented the PowerPoint), the date it was del...
Q: What are the similarities and differences between authentication and authorization? What, if any, is...
A:
Q: Create a Console application namedFirstNameLastName3CB Save the application in the FirstnameLastnam...
A: Save the below code in FirstNameLastName3CB named folder
Q: what is the final truth value for the following compound propositions using truth table: (from top t...
A: Ans B is the right one but it is written as bottom to top ,other options are not fitted acc to the g...
Q: What are the three most important characteristics of a successful network? Describe one using your o...
A: Introduction: A network must be able to meet a variety of requirements. The three most crucial are p...
Q: take a look at the udp header 12 03 00 0f 00 1e a3 10 12 03 00 0f 00 1e a3 10 what is the udp's over...
A: Introduction: The header of User Datagram Protocol (UDP) is divided into "4" sections.
Q: virtual private network (VPN) and what technologies are used to establish one
A: What is a virtual private network (VPN) and what technologies are used to establish one? Ans...
Q: Input: A list of currency exchange rates separated by ';'. A currency pair to calculate separated by...
A: The solution to the given problem is below.
Q: Write a program that reads an integer and displays all its smallest factors in increasing order. For...
A: start input number find smallest factors for(int i=2;i<=num;) { if(num%i==0) { ...
Q: What exactly do you mean by Data Purging
A: Defined about Data Purging
Q: Which column of the Zachman Framework specifies the essential knowledge required for Process Mining ...
A: - We need to talk about the process mining activity column of Zachman framework. - There are 6 col...
Q: Write a Java program to convert the decimal number to binary number. Take the decimal number from th...
A: Required:- Write a Java program to convert the decimal number to binary number. Take the decimal num...
Q: Further increases in connection speeds available to businesses and consumers from local Internet Ser...
A: predicted by _________ law
Q: Assume that u(x,y)=x2+y2u(x,y)=x2+y2, y(r,t)=rsin(t)y(r,t)=rsin(t) and x(r,t)=rcos(t)x(r,t)=rcos(t...
A: Let's see the solution in the next steps
Q: Your task is to check whether java is perfectly installed on your computer or not. for this, you hav...
A: Task : Get vendor name Get vendor url Get Java Runtime version Get Java Version
Q: Using a single print command, print the list of odd entries in x and then the list of even entries i...
A: The following is the one-line statement which prints the odd elements and even elements: print([i ...
Q: What role does the TCP/IP protocol play in LANs? Give two concrete examples.
A: Introduction: TCP/IP (Transmission Control Protocol/Internet Protocol) is a communication architectu...
Q: 1. Use nested For-loop to produce the following output. Please enter an integer between (2 and 20) :...
A: As there is no programming language mentioned so program is attempted in c++ Start input number of ...
Q: 7. problems do not have defined solutions, since they infrequent basis. Occur on an
A: NOTE: In this question, we are asked to answer the 7th and 8th question. Clearly 7th question comes ...
Q: Q3: Write the constructor's headers of the followings? new Student (202101156, "Ahmed"); new Address...
A: let's make constructor's header
Q: Is this correct in computing the time complexity in executing the program by using the formula in co...
A: Time complexity is used to measure time computation of algorithm.
Q: (20%) Some RISC-V assembly instructions are shown below. Assume that the variables f,g are assigned ...
A: check further steps for the answer :
Q: Customer Support, Inc. (CSUP) is a large corporation with international clients that provides custom...
A: This object must have a uniqueId instance variable. Need all getters and setters and toString method...
Q: Computer A uses the Go-back-N ARQ protocol to send a 110 Mbytes file to computer B with a window siz...
A: Given Data: Bandwidth = 500 Mbps Propagation delay (Tp) = 15 ms Frame size = 100K bytes Go back N i...
Q: class A{ public: class B{ public:
A: Answer: False
Q: ate the Fragments-type app, -firstinitialLastnameFragmen ments as is done in the vide karound colors...
A: Ans: <!-- Base application theme. --><style name="AppTheme" parent="Theme.AppCompat.Light.N...
Q: You have been brought in as a network consultant to troubleshoot complex network problems in an exst...
A: Steps used for network troubleshooting.
Q: What exactly do you mean by Data Purging?
A: Unused or inactive data present in database consumes space and slow down query execution. Administra...
Q: C++ NOTES FROM MY TEACHER: okay, first your gonna need to set your curPtr to null. Otherwise, the w...
A: In order to reverse a doubly linked list all we need to do is swap prev and next pointers for all no...
Q: #include int main() { int i; printf("%d\n", scanf("%d", &i)); return 0; }
A: As we know scanf returns the number or the input which is given by the user and here as specified in...
Q: Your task is to check whether java is perfectly installed on your computer or not. for this, you hav...
A: Ans : Code: public class Main{ public static void main(String[] args) { System.out.println("\nJav...
Q: Write a short Python program to support your answer (for example, show that you checked whether ther...
A: Answer: We need to check for that the smallest number for the equation given is f that we check. - W...
Q: 1. If I'm using the and operator with two conditions that are both false, what is the boolean value?
A: For given two conditions like condition1 and condition2 with a (&&) ampersand symbol, if bot...
Q: If sender A sends 12 data packets to B using the stop wait method, and the third packet is lost duri...
A: INTRODUCTION: A sender is a person who encodes and transmits a message to a receiver via a specific...
Q: Without using any loop In PHP programming languague The value of the input variable is 9,3,5,5,78 Ho...
A:
Q: flowchart a process to make change for a given value using quarters, dimes, nickels and pennies. Ask...
A: Code:
Q: Let A = {1,2,3, 4, 5} and B = {1,2, 3, 4, 5, 6}. Give a set T C A®B so that following three constrai...
A: A = {1,2,3,4,5}, B = {1,2,3,4,5,6} Tꓯ€ᴟø We have given relationship ᴝ AøB With three constraints ꓯa...
Q: d) You are developing a software in Object-Oriented approach, conduct a plan to test your software.
A: plan for test object-oriented approach
Q: 12. Write a loop of the specified type that sums up the even integers between 1 and 21. a. a while l...
A: ANSWER:-
Q: Explain the fetch-decode-execute cycle's steps. What happens in the various registers should be incl...
A: Given The answer is given below.
SUMMARY: -
Hence, we discussed all the points.
Trending now
This is a popular solution!
Step by step
Solved in 2 steps with 1 images
- Create an abstract class called Shape with the protected member String shapeName. It should have two public abstract methods getArea and getVolume. Finally, it should contain a public String method called getName which returns the shapeName. You should create a Circle class, Square class, Rectangle class, Triangle class which extend the Shape class. Each class should contain the necessary private variables. For example, a square has a side. The area and the volume can all be derived from the side value so the only private variable necessary for the square class is the side. The circle requires a radius. The triangle requires a base, length and a height. Finally, the rectangle requires length, height and width. The classes should also contain constructors and appropriate implementations of the two abstract methods getArea and the getVolume. **Shape Calculator** Enter 1 for a Circle Enter 2 for a Square Enter 3 for a Rectangle Enter 4 for a Triangle Enter 5 to Exit You should use a…Write the code below for the Computer class. The Computer class must be an abstract class, and have the following methods and attributes: • a public string called HostName • a private int called MemorySize • a public abstract method called shutdown that takes no arguments and returns nothing • a public abstract method called runProgram that takes a String for the name of the program and returns a boolean. • Also include getter/setter methods for the attributesCreate abstract class Pet , which is the abstract superclass of all animals. Declare a integer attribute called legs, which records the number of legs for this animal. Define a constructor that initializes the legs attribute. Declare an abstract method eat. Declare a concrete method walk that prints out something about how the animals walks (include the number of legs). Create the Dog class. The Dog class extends the Pet class. This class must include a String attribute to store the name and food of the pet Define a default constructor that calls the superclass constructor to specify that all dogs have 4 legs and name. override the eat and walk method. Create the Cat class that extends Pet. This class must include a String attribute to store the name of the pet, and a string to save food . Define a constructor that takes one String parameter that specifies the cat's name and food. This constructor must also call the superclass constructor to specify that all cats have four legs.…
- Create abstract class Pet , which is the abstract superclass of all animals. Declare a integer attribute called legs, which records the number of legs for this animal. Define a constructor that initializes the legs attribute. Declare an abstract method eat. Declare a concrete method walk that prints out something about how the animals walks (include the number of legs). Create the Dog class. The Dog class extends the Pet class. This class must include a String attribute to store the name and food of the pet Define a default constructor that calls the superclass constructor to specify that all dogs have 4 legs and name. override the eat and walk method. Create the Cat class that extends Pet. This class must include a String attribute to store the name of the pet, and a string to save food . Define a constructor that takes one String parameter that specifies the cat's name and food. This constructor must also call the superclass constructor to specify that all cats have four legs.…Create abstract class Pet , which is the abstract superclass of all animals.Declare a integer attribute called legs, which records the number of legs for this animal.Define a constructor that initializes the legs attribute.Declare an abstract method eat.Declare a concrete method walk that prints out something about how the animals walks (include the number of legs).Create the Dog class.The Dog class extends the Pet class.This class must include a String attribute to store the name and food of the petDefine a default constructor that calls the superclass constructor to specify that all dogs have 4 legs and name.override the eat and walk method.Create the Cat class that extends Pet.This class must include a String attribute to store the name of the pet, and a string to save food .Define a constructor that takes one String parameter that specifies the cat's name and food. This constructor must also call the superclass constructor to specify that all cats have four legs.Override walk…Java Object Oriented Programming Create a Shape class that shall have color and filled instance variables of enum Color and boolean type. The filled boolean variable shall show, whether the shape is filled (colored). The enum Color shall be defined within the class having 4 color names (choose any four). Also define getArea and getPerimeter method in Shape class, both shall return 0. Create Rectangle class with length and width attributes and a Circle class with radius attribute, of type double. Properly encapsulate all fields. Circle and Rectangle shall extend Shape class and override getArea and getPerimters methods as per its type and specific formula. In Test class, create an object of Rectangle and Circle, by initializing all attributes in constructor and print both shapes' area and perimters. In Test class, define a static method with following signature, public static void printEachShapeCount(Shape... shapes) As you know, the parent type variable can hold the…
- Question 6 Create a set of classes and interface for the following scenario: Define an interface called Classical Music, which contains a get Year method that returns the year the classical album released. Create an abstract class Called CD. This class contains the title as String, and playingTime as integer (e.g. 60 minutes). Include a constructor to initialize all the data fields. Create an abstract method called printPlayingTime to show the CD playing details. Make sure all the data fields can be accessed directly from the child classes. Create a class called Album that inherits from the CD and Classical Music. Include a data field called year as integer type. Create a constructor to initialize all the data members. Override the getYear method to return the released year. Override the printPlayingTime method. If the CD title is more than 10 characters, this method will print the first 10 characters, followed by the three ellipse dots and the playing time. For example: Thriller 60…Create an abstract class called vehicle. The class should declare the following variables: an instance variable that describes the model - String an instance variable that describes the number - String an instance variable that describes the maker - String an instance variable that describes the price - double an instance variable that describes the year – integer Provide a toString() method that returns the information stored in the above variables. Create the getter and setter methods for each instance variable except price. Provide the necessary constructors. Include an abstract method setPrice(double price) to determine the price for a vehicle. Include an abstract method getColor() to return the color of the vehicle. Create two subclasses called Car and Truck . These subclasses should override the abstract methods setPrice and getColor of class vehicle. Use the following rule for setting the price for a vehicle: car will have a 30% discount per each vehicle truck…It is required to develop an application in Java to perform some operations to store information about items in a store. The application will have the following classes: (A) An abstract class called Item having following data fields (private): itemName (String), itemNum (int), make(String), price(double) and following methods: (i) Default constructor - without any parameters, (ii) Constructor having 4 parameters to initialize all data fields, (iii) Set and get methods for all data fields separately, (iv) toString method to return string representation of all data members, (v) Abstract method totalPrice to return total price. (B) Write a concrete class (with implementation of all methods) called Storeltem, which inherits the properties of class Item. This new class has the following additional members: Data fields (private): quantity (int), discountRate(double). Note that discountRate is % of the sale price. Methods (public): (i) Default constructor - without any parameters Constructor…
- The interface Speaker is describe below. public interface Speaker{ public void speak(); public void announce(String str); } Create classes Dog and Philosopher implementing the Speaker interface. (The code for the general overview of the classes are provided you just need to fill the method and class headers and their code) and then create a driver class showing the abilities of interface, these tests are includes the ability of creating an object of Dog and Philosopher with interface reference, testing their polymorphic ability with invoking the methods of interface. and showing how we can use a method of child class of interface (Pontificate for the case of philosopher) using casting. i will include the templates below which you will use to answer the question. you will just need to input the missing codes in the required spaces. //******************************************************************** // SpeakerTest.java Author: Lewis/Loftus // // Solution to Programming Project 10.3…1. Create abstract class Pet , which is the abstract super class of all animals.1. Declare an integer attribute called legs, which records the number of legs for this animal.2. Define a constructor that initializes the legs attribute.3. Declare an abstract method eat.4. Declare a concrete method walk that prints out something about how the animals walks (include the number of legs).2. Create the Dog class that implements Pet class.1. This class must include a String attribute to store the name and food of the pet2. Define a default constructor that calls the super class constructor to specify that all dogs have 4 legs and name.3. override the eat and walk method.3. Create the Cat class that Implements Pet class.1. This class must include a String attribute to store the name of the pet, and a string to save food .2. Define a constructor that takes one String parameter that specifies the cat's name. This constructor must also call the super class constructor to specify that all cats have…Create a class Animal and Add a protected data member named id of integer type. Add get/set methods for id data member in Animal class with public access. Also provide default constructor this should initialize id to 0. Also provide parameterized constructor and toString method. Add an abstract method tellAboutSelf method to Animal class with public access Add another abstract method speak method to Animal class. Reptile, Bird, Mammal Next create the three child classes which extends form Animal class. Add a default constructor to each of the above created class. The constructor should initialize the id data member id, Reptile, Bird and Mammal, to 1, 2 and 3 respectively also it display a message “(class Name)’s default constructor”. E.g. for Bird it says “Bird’s default constructor”. Add a parameterized constructor to each of the above created class. The constructor should initialize the id data member, Reptile, Bird and Mammal, to the specified id passed to the constructor also it…