Question (2) Create a new package (employee2), solve the error and trace the output import employee.Employee; public class employee2 { public static void main(String[] args) { Employee empl = new Employee(); emp1.firstName = "Ali"; empl.lastName = "Omar"; empl.salary = 20000; empl.employeeSalary(); empl.checkEmployeeSalary(emp1.salary, 5000); }
Q: Routers are used to move data between computers. Differentiate between two frequently used types of…
A: Routing is a process that is carried out by layer 3 (or network layer) devices to transmit a packet…
Q: 6.- Write a C function to count the number of events (rising edges) in the TOCKI pin of the…
A: Answer : #include<reg51.h> sbit T1 = P3^5; void main(void) { T1 = 1; TMOD = 0x60; TH1 = 0;…
Q: Write a C program containing a recursive function that will get the whole number quotient result of…
A: The C program along with the snapshot of code and output is given below:
Q: Is a static or dynamic routing route better for a basic network, and if so, why? Which one do you…
A: Given: Static Routing is the best option when the user is connected to the principal network. When a…
Q: How can man-in-the-middle (MITM) attacks be avoided? Step by step, provide your answer.
A: In a man-in-the-middle attack, the culprit places himself in a continuous communication or data move…
Q: Learn about agile system development by visiting three websites. You should compile a list of the…
A: Alige methodology : The Alice technique employs a development process that includes many cycles of…
Q: Clock Speed, Instructions Per Second, and Instruction Execution Rate are some of the metrics used to…
A: Computer: The processor, commonly known as the CPU, supplies the computer with instructions and…
Q: What are the advantages of doing regular backups in systems administration?
A: Your answer is given below. Introduction :- A backup, also known as a data backup, is a copy of…
Q: If you are writing a while loop that increases the counter variable i by 1, and want the loop to…
A: According to the information given:- We have to find out the correct option to satisfy the…
Q: What's the biggest difference between a home phone and an Internet connection?
A: Introduction: Internet access and phone service are separate.
Q: Find the error(s) in the following class definition: public class Circle { private double radius;…
A: Ans: The error in the following class definition is that in the get and the set function the get…
Q: When surfing online, you get some strange data on an apparently secure website, and you realize you…
A: Introduction Digital certificate: A digital certificate could be a internet authentication…
Q: 1. i. (⌐ p ↔ q) is logically equivalent to ii. what is first truth - tree decomposition rule that…
A: Here, we are asked in first part about logically equivalent to (⌐ p ↔ q). And in second part we are…
Q: In what way do dynamic routing systems contribute to their overall goal?
A: The main goal of dynamic routing protocols: When possible pathways change, the dynamic routing…
Q: Assume p1, p2, and p3 are pointers to integer numbers. As an exampl consider int n1 = 33; int n2 =…
A: Answer
Q: Describe the mechanism of a DDoS attack: how it works, who the participants are, and what the…
A: Describe the DDoS attack methodology: how it works, who is involved, and what is the expected…
Q: With practical examples, discuss the difference(s) between a Web Server software and a Web Client…
A: Web Server Software: A web server is nothing but a combination of hardware and software that uses…
Q: BIG DATA HAS BECOME A PART OF EVERY ORGANIZATION'S INFORMATION TECHNOLOGY SYSTEMS IN TODAY's WORLD.…
A: Given: Big data has become a part of every organization's information technology systems in today's…
Q: Which JavaScript method should you apply to respond to a click event that occurs within the page…
A: document.getElementById("total").addEventListener("click", calcTotal, true); is the correct syntax.
Q: Asynchronous Transfer Mode (ATM) traffic management features that are performed to prevent…
A: The ATM Network concept is a compromise: between the audio, video, and computer data transfer needs…
Q: define and explain the administration and maintenance of networks without the use of plagiarised…
A: A business should keep its network secure enough so as to flourish the business.
Q: OA Mathematics 110 class at a junior college must select 3 students to serve on an advisory…
A: the solution is an given below :
Q: Analyzing a system is a challenging task. What are the challenges? When examining a system to see…
A: 1. Analyzing a system is a challenging task. What are the challenges? Challenges: When working on…
Q: Address Resolution Protocol (ARP)
A: Address Resolution Protocol (ARP) Address Resolution Protocol (ARP) is a communication protocol used…
Q: Is a dot-matrix printing machine better than an ink-jet printing machine, or the other way around? A…
A: Printer (dot matrix): A dot-matrix printer and a line printer are both output devices, however they…
Q: Face-to-face communication varies from computer-mediated communication in many ways. Disseminate…
A: Using computers as a medium for communication is called computer-mediated communication (CMC).…
Q: A denial-of-service (DDOS) attack is one that prevents a website from functioning properly.
A: DDOS: Denial of service (DoS) attacks that extend over an entire network are known as "distributed…
Q: Consider the following class defintion for class named MyClass and answer the following questions.…
A: The syntax for creating object of the class is as follows: 1. For default constructor Classname…
Q: How does distributed routing work? Is there an antithesis to distributed routing?
A: Using a distributed model looks to be a suitable choice for a purely " opaque domain," meaning that…
Q: In what ways is data security at risk? Then, how do we deal with these threats?
A: A security risk is anything that might: result in a trade-off, misfortune, inaccessibility, or…
Q: --If (AL)-ED H, (DS)-200H and 20.Physical address is (BX)=1000 H. 21.Physical address is (BP)=74FE…
A: According to the information given:- We have to fill in the blank with appropriate answer.
Q: When a change is made to the database schema, why is it beneficial for the DBMS to automatically…
A: Database schema: System tables are specific tables that the system employs to regulate data and the…
Q: Q2\ write an oop program to read and print information about you ? 1 Add file
A: Start Take the input from user Read the input Print the data Stop
Q: Write a C program containing a recursive function that will get the whole number quotient result of…
A: Given: To write a C program to find quotient of two numbers.
Q: In what ways are machine language and assembly language distinct from one another?
A:
Q: After a timeout, we considered increasing the timeout interval. Congestion may be reduced by using…
A: Definition: TCP with a congestion control strategy based on widows If TCP were a stop-and-wait…
Q: write a java program to print the mirror image of right angled in x-direction after taking number of…
A: Find:- After receiving a number of rows from the user, write a Java application to produce the…
Q: cache.xls (or it can be a google sheet that you share with me in a cache.txt with the url in it )= a…
A: Given: cache.xls is a spreadsheet that is showing the cycle counts of a cached and non-cached…
Q: What are the most often used protocols for routing data? What factors are taken into account by…
A: Protocols for routing data: Exterior routing protocols are used to exchange routes across networks…
Q: We need to know about network topologies
A: Introduction In total there are five network topologies they are : 1. Bus Topology : The data…
Q: Describe briefly how you propose to examine this DDoS assault using security engineering techniques
A: Answer :
Q: Q5: For the Binary search tree given below. 30 15 60 7 22 45 75 17 27 In-order Travetrsal Pre-Order…
A: The postorder traversal is one of the traversing techniques used for visiting the node in the tree.
Q: Are there any applications where a dot-matrix printer is more suited than another form of printer,…
A: A Dot Matrix Printer is the oldest type of printer and one of the good examples of computer printer…
Q: UI/UX is made possible by informaticists because they have a thorough understanding of how to use…
A: system capability: It is the capacity of a system to carry out a certain course of action or to…
Q: The next sections go into great detail on network applications and application layer protocols.
A: Network applications include: As network functions become more virtualized and network control…
Q: The OSI layer, its functions, and the protocols that operate at each layer will be discussed in this…
A: In Computer networks OSI layer stands for Open System Inerconnection. It is a architecture…
Q: Given a sequence of 5 element keys for searching task: a) Given the hash function H(k) = (3.k) mod…
A: Hash table:- Hash table is data structure in which keys are stored in array format and each key has…
Q: Which VLAN is intended to provide administrative access to network devices?
A: Answer :
Q: We contemplated raising the timeout period after one of our users had a timeout. This is a method of…
A: Foundation: Window-based congestion control is used by the Transmission Control Protocol…
Step by step
Solved in 3 steps with 1 images
- 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); } }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…C# problem when printing Weigh no value shows up code public class HealthProfile{private String _FirstName;private String _LastName;private int _BirthYear;private double _Height;private double _Weigth;private int _CurrentYear;public HealthProfile(string firstName, string lastName, int birthYear, double height, double weigth, int currentYear){_FirstName = firstName;_LastName = lastName;_BirthYear = birthYear;_Height = height;_Weigth = weight;_CurrentYear = currentYear;}public string firstName { get; set; }public string lastName { get; set; }public int birthYear { get; set; }public int height { get; set; }public double weight { get; set; }public int currentYear { get; set; }public int Person_Age{get { return _CurrentYear - _BirthYear; }}public double Height{get { return _Height; }}public double Weight{get { return Weight; }}public int Max_Heart_Rate{get { return 220 - Person_Age; }}public double Min_Target_Heart_Rate{get { return Max_Heart_Rate * 0.65; }}public double…
- 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…class Lease{ private String name; private int aptNumber; private double rent; private int term; private static final int FEE = 10; public Lease(){ name = "XXX"; aptNumber = 0; rent = 1000; term = 12; } public void setName(String tenant) { name = tenant; } public void setAptNumber(int apt){ aptNumber = apt; } public void setRent(double monthRent) { rent = monthRent; } public void setTerm(int t){ term = t; } public String getName(){ return name; } public int getAptNumber(){ return aptNumber; } public double getRent(){ return rent; } public int getTerm(){ return term; } public void addPetFee(){ rent = rent + FEE; } } Create a class named TestLease as instructed below: Instantiate four Lease objects in the main()method. Change the aptNumber value for the first object to 20 Change the rent value…
- //PLEASE CORRECT MY MISTAKES, THANK YOUpublic 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);…class Main { publicstaticvoid main(String[] args) { // Coin myPenny = new Coin(CoinType.PENNY); // Coin myNickel = new Coin(CoinType.NICKEL); // Coin myDime = new Coin(CoinType.DIME); // Coin myQuarter = new Coin(CoinType.QUARTER); // Coin myHalfDollar = new Coin(CoinType.HALF_DOLLAR); // Coin myDollar = new Coin(CoinType.DOLLAR); // System.out.println(printValue(myPenny)); // System.out.println(printValue(myNickel)); // System.out.println(printValue(myDime)); // System.out.println(printValue(myQuarter)); // System.out.println(printValue(myHalfDollar)); // System.out.println(printValue(myDollar)); } publicstatic String printValue(Coin c){ String result = ""; // result = String.format("The value of a %s is $%.2f", c.getName(), c.getValue()); return result; } }package myq2; class Sale { int sellerID, milksale, buttersale; Sale(int sid, int ms, int bs) { sellerID = sid; milksale- ms; buttersale - bs; } elling dairy ifferent days using OOP ers, based on YQ2 int totalsaving(){ return milksale + buttersale; } } ale public class Myq2 { public static void main(String[] args) { Sale s = new Sale(111, 10, 20); System.out.println("Seller ID" + s.sellerID ); System.out.println("Total Saving "+s.totalsaving()); } } 4) Use the parameterized constructor to initialize the member variables of the class. 5) Display the following details of seller using object of Sale class. seller ID, totalsaving Solution to program
- 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?Student Information using Constructors Write a java program using parameterised constructor to display student details such as student name, student branch, student college.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 error