computer science questions and answers

Model the following in a Java program: In a software engineering project, we are developing software…

Question: Model the following in a Java program: In a software engineering project, we are developing software for an automobile production plant. Wehave the following users in the system: Worker and Manager. Each of these is a user and every user hasname, surname, username, password and address. The worker can be AutoWorker, TruckWorker orBusWorker. The …

Model the following in a Java program: In a software engineering project, we are developing software… Read More »

Floating Point Representation: Show how each of the following floating point values…

Question: Q.1. Show how each of the following floating point values would be stored using the simple model described in the textbook (14-bit format, 5 bits for the exponent with a bias of 15, a normalized mantissa of 8 bits, and a single sign bit). Express your answer in both binary and hexadecimal:22.5-3.50.762525.325 Answer: Q.2. …

Floating Point Representation: Show how each of the following floating point values… Read More »

Your task is to write a C++ program which computes a set of a target heart rate…

Question: Your task is to write a C++ program which computes a set of a target heart rate values associated with human exercise research.The formulas you will need can be found on the following web page: http://en.wikipedia.org/wiki/Heart rate Your program should prompt the user for two integers, the subject’s age in years (age) and the …

Your task is to write a C++ program which computes a set of a target heart rate… Read More »

Suppose two binary trees, T1 and T2, hold entries satisfying the heap-order property…

Question: Suppose two binary trees, T1 and T2, hold entries satisfying the heap-order property (but not necessarily the complete binary tree property). Describe a method for combining T1 and T2 into a binary tree T, whose nodes hold the union of the entries in T1 and T2 and also satisfy the heap-order property. Your algorithm …

Suppose two binary trees, T1 and T2, hold entries satisfying the heap-order property… Read More »

Write a C++ program in which you are required to define a class named Citizen…

Question: Write a C++ program in which you are required to define a class named Citizen. The class must include the following two data members.NameNationalityYour Program should define three constructors for the class Citizena constructor with no parametera copy constructorAll of these constructors are meant to initialize their respective objects. In the case of the …

Write a C++ program in which you are required to define a class named Citizen… Read More »

Develop a flowchart and then write a menu-driven C++ program that uses several user-defined functions, overloaded functions, and references.

Question: Develop a flowchart and then write a menu-driven C++ program that uses several user-defined functions, overloaded functions, and references. Upon program execution, the screen will be cleared and the menu shown below will appear at the top of the screen and centered. The menu items are explained below.                                 Help                        Smallest                        Largest                       Quit H or h ( for Help ) option …

Develop a flowchart and then write a menu-driven C++ program that uses several user-defined functions, overloaded functions, and references. Read More »