SELECT ALL of the class fields/variables from the class declaration below.
Q: Write an algorithm and draw a flow chart to calculate the area of triangle and calculate the area of...
A: Algorithm: Start Read Length L and Breadth B Calculate triangleArea=0.5*L*B Calculate rectangleArea...
Q: What does the phrase "interdependence" mean in terms of system concepts, and how does it vary from o...
A: Introduction: Interdependence is the situation of being mutually reliant or simply dependent on one ...
Q: I have the code bellow. Now I'm ask to display the number of elements in the arrays read from files...
A: #include <iostream>#include <fstream>using namespace std; class Multiplicity { //Class p...
Q: Assume that ???????????? is a subclass of ???????, select all the codes that override the ??????????...
A: Inheritance in JAVA is a OOPs concept in which one class acquires all the properties and behaviors o...
Q: What is the ARM statement which correspond to the each following statement and find the value of RO?
A: The answer is
Q: The number (+46.5), as a floating-point binary number with 18 bits consisting of one sign bit, 11-bi...
A:
Q: Payroll is a good example of when it makes sense to do a lot of work at once, using magnetic tape. P...
A: Introduction: A storage device is a device that stores, extracts, and transmits data from files.
Q: What hardware component permits a device's physical network connection?
A: Introduction: A modem is a piece of hardware that allows a computer to connect to the internet via a...
Q: SELECT ALL of the valid statements that instantiate an object from the Bicycle class shown below
A: Bicycle bike = new Bicycle(1,1,1);
Q: The enqueue operation should be classified as a "transformer". True False
A: The queue data structure contains two operations Enqueue and Dequeue. Enqueue means adding the eleme...
Q: Design a security solution that can ensure the authenticity of IP packets routed in a company intran...
A: the answer is given below:-
Q: Let S1 and S2 be two stacks. 1. It is possible to keep two stacks in a single array, if one grows fr...
A: Create a data structure twoStacks that represents two stacks. Implementation of twoStacks should use...
Q: Show that the language {www | w e {a,b}*} is not context-free.
A: We can show a language is not context-free using Pumping lemma for context free languages Pumping le...
Q: How do you find out what kind of motherboard you have in order to fix it?
A: Introduction: How do you find out what kind of motherboard you have in order to fix it?
Q: Who was the first person to develop a computer processor
A: Introduction; The First Mainframe Computer has Invented: Mainframe computers are typically utilized ...
Q: j. Declare a string variable containing the word "TEST" repeated 500 times. k. Declare an array of 2...
A:
Q: There are different stages in the instruction cycle.
A: Introduction: there are different stages in the instruction cycle
Q: When working with a recursive function, what data structures should be used and why
A: Recursion is a process of calling the function itself Once the function executes, it stores the resu...
Q: Let E be an alphabet and A C E*. (a) If c E £ and AC E*, we define APPEND.(A) as {wc ɛ E* | w E A}. ...
A: Below is the answer to above question. I hope this will meet your requirement
Q: 2. Consider the system to be 64 bit, answer the following question in accordance to C language, i) ...
A: To find the size of int, char, int *, and char *, consider the system to be 64-bit and in accordance...
Q: ck the temperature of t
A: A computer's central processor unit (CPU) must be kept at a consistent temperature to perform at its...
Q: use Java to output the character "Z" and make it to rotate 360 degrees clockwise
A: Java Code to print Z and rotate it by 360 degree clockwise. import java.util.Scanner;public class My...
Q: Consider a two-link network where Host A is connected to the router by a 1 Mbps link with 10 ms
A: The answer is
Q: In the face of substitutability, invocation of overridden methods makes use of _ binding, in which t...
A: Dynamic Binding: When type of the object is determined at run-time, it is known as Dynamic Binding....
Q: Discuss a situation in which you’ve encountered difficulty understanding data (Information). What ar...
A: What are the problems to understand the data The structure The size The dimensions (in some cases ...
Q: What are the most pressing email security issues?
A: Introduction: The most serious security problems concerning email communications security,
Q: Help me do the code by follow the descriptions. Import Java Scanner class
A:
Q: What are the differences between internal and external file labels? What is the purpose of them?
A: Intro What are the differences between internal and external file labels? What is the purpose of t...
Q: Malicious destruction of a hardware device is: O breach of availability breach of confidentiality br...
A: Whenever an individual is willing to destroy or destroy electronic documents, information, or softwa...
Q: https://www.youtube.com/watch?v=Rtc0eeh1pSs&t=5318s What is deep data? Briefly explain about it. G...
A: Deep data or information alludes to huge information that is of top notch, important, and noteworthy...
Q: Define the characteristics that are required for test-driven development. In the event that you wish...
A: Test-driven development refers to a style of programming in which three activities that are: coding,...
Q: 7. If the formula in CELL A4 is copied to cell B5, what value will appear in that cell? A C 1 1 2 3 ...
A: =A1+B1 will return the sum of A1 and B1 it is A1 is 1 B1 is 2 So the result is 3.
Q: Question1. Write a PHP function to change the following array's all values to upper or lower case. S...
A: I give the code in Php as per your requirement along with output and code screenshot
Q: Prove that a uniform scaling and rotation from a commutative pair of operations, in general, are not...
A: Rotations in pc pictures is a transformational operation. meaning that it's miles a conversion from ...
Q: Computer Science Question: Consider a virtual cylinder identical to the one shown the figure below ...
A: Below is the answer to above question. I hope this will be helpful.
Q: number = input() while number!=id: print("This is not your ID number.") number = input() ...
A: Actually you can do without f strings too. Just put whatever you want to put after "...ID number:(he...
Q: Liam wants to use defined names in other calculations to help him interpret the formulas. In the ...
A: For defining the name range in Excel, we follow the following steps: 1) We select the cells B4:C8
Q: Write a program in C that asks the user to enter a number of seconds and works as follows: • There a...
A: Sun, 23:49// TEXT CODE // prompt the user to get the number of seconds var numberOfSeconds = window....
Q: Write a Java Program to count the total number of characters in a string
A: import java.util.Scanner; public class Count_WordOfString{ public static void main(String args[]){ S...
Q: A multicore computer is a computer that
A: A multicore computer is a computer that has a lot of different parts.
Q: If the input is 5. 0 2.5 1.5 the output is 55.90170 579.32402 5.00000 6.64787
A: here is Pseudo-Code of the :- (i) start (ii) input three floating number (iii) calc...
Q: What model is used to assess the reliability of software?
A: Introduction: Models of software reliability growth are statistical interpolations of defect detecti...
Q: cleAndSphere.java // Step 1: Import the Scanner class for input import java.util.Scanner; /** * A Ja...
A: CORRECTED PROGRAM CODE: // Step 1: Import the Scanner class for inputimport java.util.Scanner;/* * A...
Q: When you think about a motherboard, what does it look like?
A: INTRODUCTION: The primary printed circuit board of general-purpose computers and other extensible s...
Q: Convert the following regular expressions to Non-deterministic Finite Automata (NFA): a) (b|c)*a(a[c...
A:
Q: allocation
A: Computer programs and services assign physical or virtual memory space by a process called memory al...
Q: If you have previous experience troubleshooting wireless LAN's, give an example of a scenario you ha...
A: NOTE :- Below i explain the answer in my own words by which you understand it well. Wireless ne...
Q: Write the following two programs: Extend a multi-threading Java program to accept a number from the ...
A:
Q: You are required to model a vehicle parking lot system.
A: Program Explanation: Import the util and text classes Define a class for implementing the parking...
Q: What exactly is the distinction between hardware and software?
A: Some distinction between hardware and software Hardware It generally refers to the physical part of...
SELECT ALL of the class fields/variables from the class declaration below.
Step by step
Solved in 2 steps
- public class LabProgram { public static void main(String args[]) { Course course = new Course(); String first; // first name String last; // last name double gpa; // grade point average first = "Henry"; last = "Cabot"; gpa = 3.5; course.addStudent(new Student(first, last, gpa)); // Add 1st student first = "Brenda"; last = "Stern"; gpa = 2.0; course.addStudent(new Student(first, last, gpa)); // Add 2nd student first = "Jane"; last = "Flynn"; gpa = 3.9; course.addStudent(new Student(first, last, gpa)); // Add 3rd student first = "Lynda"; last = "Robison"; gpa = 3.2; course.addStudent(new Student(first, last, gpa)); // Add 4th student course.printRoster(); } } // Class representing a student public class Student { private String first; // first name private String last; // last name private double gpa; // grade point average…Public Class SavingsAccount { float interest; float FixedDeposit; SeniorAccount(float interest, float FixedDeposit) { this. interest = interest; this.fixedDeposit= FixedDeposit; } float calculateInterest(); { System.out.println(“Calculating Savings Account Interest”); return(FixedDeposit*interest/100); } } Public Class SeniorAccount extends SavingAccount { float seniorInterest; SeniorAccount(float interest, float FixedDeposit) { this.seniorInterest=interest; super(interest, FixedDeposit) } float calculateInterest() { System.out.println(“Calculating Savings Account Interest”); return(FixedDeposit*seniorinterest/10); } } Public static void main(String args[]) { SavingsAccount saving = new SavingsAccount(6,100000); System.out.println(saving.calculateinterest()); SeniorAccount senior=new seniorAccount(10,100000); System.out.println(Senior.calculateInterest()); } Correct the syntax and logical errorPublic Class SavingsAccount { float interest; float FixedDeposit; SeniorAccount(float interest, float FixedDeposit) { this. interest = interest; this.fixedDeposit= FixedDeposit; } float calculateInterest(); { System.out.println(“Calculating Savings Account Interest”); return(FixedDeposit*interest/100); } } Public Class SeniorAccount extends SavingAccount { float seniorInterest; SeniorAccount(float interest, float FixedDeposit) { this.seniorInterest=interest; super(interest, FixedDeposit) } float calculateInterest() { System.out.println(“Calculating Savings Account Interest”); return(FixedDeposit*seniorinterest/10); } } Public static void main(String args[]) { SavingsAccount saving = new SavingsAccount(6,100000); System.out.println(saving.calculateinterest()); SeniorAccount senior=new seniorAccount(10,100000); System.out.println(Senior.calculateInterest()); } Rubric: Correct the syntax and logical errors Proper working code
- Based on Figure 3, create a class named Child that inherits the Father class. Declare an instance name location (String) for class Child. [3 marks]Public classTestMain { public static void main(String [ ] args) { Car myCar1, myCar2; Electric Car myElec1, myElec2; myCar1 = new Car( ); myCar2 = new Car("Ford", 1200, "Green"); myElec1 = new ElectricCar( ); myElec2 = new ElectricCar(15); } }Incorrect Question 6 public class Shape { Color fillColor; } public Shape() { fill Color = Color. RED; } } public Shape(Color fillColor) { this.fill Color = fillColor; } public class Circle extends Shape { int radius; public Circle() { radius = 1; } public Circle(int radius) { this.radius = radius; } public Circle(int radius, Color fillColor) { } super(fillColor); this.radius = radius; Circle c1= new Circle(); Circle c2= new Circle(5); Circle c3 = new Circle(10, Color.BLUE); Which of the following are correct? c2 has radius 5 c1 is red c2 is red c3 has radius 10 c3 has radius 1 c3 is red c1 is blue ✔c2 has radius 10 c3 is blue c1 has radius 5 c1 has radius 1 c2 has radius 1 c2 is blue
- Class Quiz public Quiz (int quesList, int quesMissed) {quesList = this.quesList;quesMissed = this.quesMissed;} private void calculate(){// get the point worth of each question and calculate final scorepointsPerQues = (100/quesList);scoreQuiz = quesList - quesMissed;} Class PassFailQuiz public PassFailQuiz (int quesList, int quesMissed, int scoreQuiz) { super(quesList, quesMissed);} How do I move scoreQuiz from private void calculate() to equal the third constructor value in PassFailQuiz?public class Person { private String personID; private String firstName; private String lastName; private String birthDate; private String address; public Person(){ personID = ""; firstName = ""; lastName = ""; birthDate = ""; address = ""; } public Person(String id, String first, String last, String birth, String add){ setPerson(id,first,last,birth,add); } public void setPerson(String id, String first, String last, String birth, String add){ personID = id; firstName = first; lastName = last; birthDate = birth; address = add; } public String getFirstName(){ return firstName; } public String getLastName(){ return lastName; } public String getBirthdate(){ return birthDate; } public String getAddress(){ return address; } public void print(){ System.out.print("\nPerson ID = " + personID); System.out.print("\nFirst Name = " +firstName); System.out.print("\nLast Name = " +lastName); System.out.print("\nBirth Date = " +birthDate); System.out.print("\nAddress = " +address); } public String…public class Person { private String personID; private String firstName; private String lastName; private String birthDate; private String address; public Person(){ personID = ""; firstName = ""; lastName = ""; birthDate = ""; address = ""; } public Person(String id, String first, String last, String birth, String add){ setPerson(id,first,last,birth,add); } public void setPerson(String id, String first, String last, String birth, String add){ personID = id; firstName = first; lastName = last; birthDate = birth; address = add; } public String getFirstName(){ return firstName; } public String getLastName(){ return lastName; } public String getBirthdate(){ return birthDate; } public String getAddress(){ return address; } public void print(){ System.out.print("\nPerson ID = " + personID); System.out.print("\nFirst Name = " +firstName); System.out.print("\nLast Name = " +lastName); System.out.print("\nBirth Date = " +birthDate); System.out.print("\nAddress = " +address); } public String…
- public class Player { private int jerseyNumber; private int rating; public Player(int jerseyNumber, int rating) { this.jerseyNumber = jerseyNumber; this.rating = rating; } public int getJerseyNumber() { return jerseyNumber; } public void setJerseyNumber(int jerseyNumber) { this.jerseyNumber = jerseyNumber; } public int getRating() { return rating; } public void setRating(int rating) { this.rating = rating; } @Override public String toString() { return "Jersey number: " + jerseyNumber + ", Rating: " + rating; }}public class RosterManager { private ArrayList<Player> roster; public RosterManager() { roster = new ArrayList<>(); } public void addPlayer(Player player) { roster.add(player); } public void updatePlayerRating(int jerseyNumber, int newRating) { for (Player player : roster) { if (player.getJerseyNumber() ==…This is the Exam class mentioned public class Exam { private int day; private int month; private int year; private int hour; private int minutes; private double maxMarks; private final String type; private final int order; private static int labExamCounter = 0; private static int midtermExamCounter = 0; public static final String LAB_EXAM = "Lab Exam"; public static final String MIDTERM_EXAM = "Midterm Exam"; public static final String FINAL_EXAM = "Final Exam"; public Exam(String type) { this (type, 0, 0, 0, 0, 0, 0); } public Exam(String type, double maxMarks) { this (type, maxMarks, 0, 0, 0, 0, 0); } public Exam(String type, double maxMarks, int day, int month, int year) { this (type, maxMarks, day, month, year, 0, 0); } public Exam(Exam other) { this (other.getType(), other.getMaxMarks(), other.getDay(), other.getMonth(), other.getYear(), other.getHour(),…8. OOPS Theory #6 public class Car { public void horn() { System.out.println("Horn horn"); } } public class Ferrari extends Car { public void horn() { System.out.println("Ferarriiiiii"); } } public static void main(String[] args) { Ferrari ferrari = new Car(); ferrari.horn(); } Pick ONE option Horn horn Ferarriiii Cannot compile Runtime exception Clear Selection 9. OOPS Theory #7 In Java, we can achieve the abstraction by creating the blueprint of an object and only have abstract methods. What do we call this? Pick ONE option Interface Encapsulation Instance Protected Clear Selection