Write the constructor method for class Circle which is a subclass of Shape class. Class Shape has one attribute (color) and one constructor (with one parameter). Class circle has attribute for radius.
Q: 19. How do Internet packets travel to their destination? (A) Router to router based on the…
A: The Internet enables communication and the exchange of information and resources between computers…
Q: could provide a quick overview of the compiler and then comment on the testability of the program,…
A: A compiler is a program that transforms code written in one programming language (source code) into…
Q: 3- What is the difference between social engineering and port scanning. 4- Provide the description…
A: Your answer is given below.
Q: Write in java code: a) Write class Vehicle that is superclass and abstract write only one line in…
A: a) public abstract class Vehicle { // class implementation } b) False. Class Vehicle can…
Q: When looking at purchasing a new laptop, what features should you prioritise the most?
A: Due to the various options and functions, buying a laptop might be difficult. Knowing your…
Q: Sumif, Countif Functions Kindly following the instructions below and…
A: Dear student, the answer is provided below.
Q: Why are people of various ages and backgrounds interested in computer science?
A: Your answer is given below.
Q: It is correct that Compiler Phases do not provide any extra features or bells and whistles. Every…
A: We must provide an explanation. It is true that Compiler Phases do not include any unique features…
Q: for (int i = 1; i <= 2; i++) for (int j = 1; j <= 2; j++) for (int k = 1; k <= 2; k++) { int sum= i…
A: The first for loop initializes the variable i to 1 and executes the code inside the loop body as…
Q: Write a java program that displays a flashing label. Exercise15_10 X Exercise15_10 Welcome to Java X
A: In this question we have to write a java code to display a label in the window application form…
Q: What aspects of a new laptop should you place the most importance on when making your purchase?
A: If you are in the market for a new laptop, there are a few things to keep in mind so That you can…
Q: Hello! I am having issues undertanding the code in the picture. I am mosly interested on an…
A: This is a program that uses two threads to increment a shared variable count. The variable turn is…
Q: In Python Write a program that reads movie data from a CSV (comma separated values) file and output…
A: The task is to write a Python program that reads movie data from a CSV file and displays it in a…
Q: Why do individuals of all ages and from all areas of life find an interest in the discipline of…
A: Dear learner, hope you are doing well, I will try my best to answer this question. Thank You!!
Q: Please offer some actual instances to show the differences between illegally downloading something…
A: Illegal downloading and intellectual property infringement are two separate notions , though they…
Q: Just picture the CIA's three pillars—covertness, trust, and vigilance—working in tandem.
A: The process of shielding a system or network against unauthorised entry, interruption, Or…
Q: 51. Which of the following places the numbers in ascending order?
A: The correct answer is (B) i., iii., ii. The numbers in ascending order are 92, 01011101, and…
Q: Please provide an example of one of the many different kinds of interruptions as well as an…
A: What is Computer: A computer is an electronic device that is capable of accepting input, processing…
Q: How quickly can you transfer data over an Ethernet LAN?
A: Ethernet LANs can transfer data at high speeds, with Gigabit Ethernet being able to transfer data at…
Q: Tell me about a moment when you were participating in an online course or programme and you had…
A: I provided general suggestions on how to effectively communicate in such an environment. These…
Q: How fast can information travel across an Ethernet LAN?
A: Ethernet LAN (Local Area Network) is a type of network technology that connects computers, servers,…
Q: Is there anything you would do if you found a virus on your mobile device? Learn more about the…
A: In this question we have to understand what are the prevention measures if we found a virus on a…
Q: Design and explain a generic m-round winner tournament, Round-Winner-Tournament(P,m), for players P,…
A: We have to design and explain a generic m-round winner tournament, Round-Winner-Tournament(P,m), for…
Q: a specific word. Each text file contains synonyms for the word specified in the file’s name, and…
A: We're going to create a Python program that reads a set of text files containing synonyms for…
Q: should you focus on when shopping for a new laptop
A: What should you focus on when shopping for a new laptop?
Q: If you want to be successful as a computer manufacturer, one of the obstacles you'll encounter is…
A: The answer is given below step.
Q: How do you determine whether or not the network is reliable, and what measures do you utilise to…
A: The answer is given below step.
Q: Questions 55-57 refer to the following code. count - 1 pets ["dog", "dogfood", "cat", "catfood",…
A: In computer programming, a list is a collection of elements that are stored in a specific order. The…
Q: it is vital to test Firebase apps on as many distinct iOS devices and versions as is humanly…
A: Firebase is an app development platform that helps you build and grow apps, games, and scalable…
Q: Do you prefer asynchronous or synchronous buses in terms of the amount of processing power and…
A: According to the information given:- We have to define asynchronous or synchronous buses in terms of…
Q: Your computer science class assignment required you to make connections between theoretical ideas…
A: In order to make abstract ideas clear, it is standard practise in computer science lectures to…
Q: When looking for a new laptop, what features should you prioritise the most?
A: In today's fast-paced world, a laptop is an essential tool for work, study, and entertainment.…
Q: In an 802.11b wireless LAN, suppose there are only two nodes, a source and a destination; the source…
A: Hello student Greetings Hope you are doing great. Thank You!!!
Q: I was hoping you could provide me some comprehensive guidelines for studying Python.
A: Your answer is given below.
Q: 4.25 Consider the following loop. LOOP: lw $s0, 0($s3) lw $s1, 8($s3) add $s2, $s0, $s1…
A: Pipeline execution diagram: A pipeline execution diagram is a graphical representation of the steps…
Q: 7. Which of the following will evaluate to false? i. false AND (true OR NOT (false) ii. true AND…
A: Hello student Greetings Hope you are doing great. As per our policy guidelines, in case of multiple…
Q: What is it about computer science that piques the curiosity of people of all ages and walks of life?…
A: Computer science is a field that is highly relevant to our daily lives, as computers and technology…
Q: 10. The video the nest watchers took of the baby sea turtles making their way to the water is too…
A: (A) Lossless compression will allow the scientists to see the video in full resolution: Lossless…
Q: have you run across any particular sorts of issues?
A: One common issue that users may encounter is compatibility issues between Firebase and the version…
Q: Implement function rotate that takes a string argument s and an integer argument n, and rotates the…
A: 1) Below is C program that defines a function rotate that takes a string argument s and an integer…
Q: Investigate the methods that people use to fix problems that have arisen when they have been using…
A: The answer is given below step.
Q: If you learned that a virus was present on your mobile device, what actions would you take? Find out…
A: Mobile device viruses may compromise security and steal sensitive data. Malicious software,…
Q: developers must create code that can be maintained even if the company does not?
A: Therefore, does this imply that developers must create code that can be maintained even if the…
Q: Consider all of the information that is currently saved on the hard disc of your computer right now.…
A: In this question we have to understand the certain things where we need to consider all of the…
Q: Should we utilise a synchronous bus to connect the CPU and the RAM, or an asynchronous bus? Do we go…
A: Should we use an asynchronous or synchronous bus to link the memory and the central processor unit?…
Q: Please explain what you mean by "technical papers." Please list four key characteristics that set…
A: Technical papers are written documents that convey specialized technical information, research…
Q: This is my solution, Please check the solution and let me know If my solution is correct: Please…
A: Hello student Greetings Hope you are doing great. Thank You!!!
Q: What exactly is it that makes certain versions of Android Pie not work properly?
A: What is an android: Android is a mobile operating system based on the Linux kernel that was…
Q: Imagine you are a producer of high-end videocassette recorders. The "user" of your XJ-6 recorder can…
A: The XJ-6 is a cutting-edge technology that allows users to configure up to 4096 possible future…
Q: If you could provide a quick overview of the compiler and then comment on the testability of the…
A: A compiler is a software program that transforms source code written in a high-level programming…
Write the constructor method for class Circle which is a subclass of Shape class. Class Shape has one
attribute (color) and one constructor (with one parameter). Class circle has attribute for radius.
Step by step
Solved in 3 steps with 1 images
- Person and Customer Classes Write a class named (Person) with data attributes for a person’s name, address, and telephone number. Provide accessors/getters and mutators/setters for each attribute. Write a displayPerson() to print out the attributes of the Person. Next, write a class named (Customer) that is a subclass of the (Person) class. The (Customer) class should have a data attribute for a customer number, and a Boolean data attribute indicating whether the customer wishes to be on a mailing list. Provide accessors/getters and mutators/setters for each attribute. Write a display customer() to print out the attributes of the Customer. Demonstrate an instance of the (Customer) class in a simple program.Define a class named Employee. This class should extend the Person class from the previous question. The class should have a constructor, which takes the name, age, employer (String) and salary (int) as parameters (in that order). The first two parameters should be passed to the constructor of the superclass and the value of the last two parameters should be stored in instance variables. The class should define the methods, getSalary which returns the salary of the employee and getEmployer which returns the name of the employer. Any methods from the previous question that need to be overridden should be overridden! Use super and instanceof as appropriate. I.e., for the following methods you should be able to call the method in the superclass for specific situations (e.g. the compareTo method in the superclass can be called if you receive anything other than an Employee, and this also holds for the equals method). The toString method only needs to append details and as such can also…The class "Car" has the following attributes: plate (String), mark (String), model (String), year (int), km (int).Write a constructor method for the "Car" class that takes values as parameters for all these attributes.
- The class "Plant" has the following attributes: name (String), family (String), lifeSpan (int). Write a constructor method for the "Plant" class that takes values as parameters for all these attributes. A- BI II !!The class "Student" has the following attributes: studentId (int), name (String), surname (String), deptCode (String).Write a constructor method for the "Student" class that takes values as parameters for all these attributes.Implement the Seller class as a derived class of Person class. Create the seller.h and seller.cppfiles for this class. The Seller class contains additional data members that hold a seller’s:o average star rating received from the buyers, ando total number of items sold.These data should be accessible by its derived classes. (should these data be private, public, orprotected?) The following methods are included in the seller class:• A default constructor and a copy constructor• A constructor that receives all of the data for a seller.(for the constructors, make sure to call the base class constructor as appropriate)• Appropriate get and set functions for the new data in this class• print() – overrides the base class print() to print the base class data and print all additionalseller data with appropriate messages. Make sure to call the base class print to print thebase class data.• read() – overrides the base class read() to read the base class data and reads all additionalseller data…
- Write the following four classes to practice using an abstract class and polymorphism. Submit all four classes. Shape2D class For this class, include just an abstract method name get2DArea() that returns a double. Rectangle2D class Make this class inherit from the Shape2D class. Have it store a length and a width as fields. Provide a constructor that takes two double arguments and uses them to set the fields. Note, the area of a rectangle is the length times the width. Rectangle2D class Also make this class inherit from the Shape2D class. Have it store a radius as a field. Provide a constructor that takes a double argument and uses it to set the field. Note, the area of a circle is PI times it's radius times it's radius. Shape2DDriver class Have this class provide a method named displayName() that takes an object from just any of the above three classes (you can't use an Object type parameter). Have the method display the area of the object, rounded to one decimal place. using JAVA…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…
- 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 an abstract CardGame which contains a “deck” of 52 playing cards that uses a Card class that holds a suit and value for each Card object. It also contains an integer field that holds the number of cards dealt to a player in a particular game. The class contains a constructor that initializes the deck of cards with appropriate values (e.g., “King of Hearts”), and a shuffle() method that randomly arranges the positions of the Cards in the array. The class also contains two abstract meb. Create two child classes that extend CardGame. You can choose any games you prefer. For example, you might create a Poker class or a Bridge class. Create a constructor for each child class that initializes the field that holds the number of cards dealt to the correct value. (For example, in standard poker, a player receives five cards, but in bridge, a player receives 13.) Create an appropriate displayDescription() and deal() method for each child class.Create a deck of cards class. Internally, the deck of cards should use another class, a card class. Your requirements are: The Deck class should have a deal method to deal a single card from the deck After a card is dealt, it is removed from the deck. There should be a shuffle method which makes sure the deck of cards has all 52 cards and then rearranges them randomly. The Card class should have a suit (Hearts, Diamonds, Clubs, Spades) and a value (A,2,3,4,5,6,7,8,9,10,J,Q,K)