Answer:
The answer to this question can be given as:
Class definition:
public class Averager //define class Average.
{
private int sum = 0;
//define variable sum.
private int count = 0;
//define variable count.
public int getSum() //define function getSum().
{
return sum; //return value.
}
public void add(int x)
//define function add().
{
sum = sum + x; //calculate sum
count=count+1; //increase value of count.
}
public int add(int x)
//define function add().
{
return count; //return value.
}
public double getAverage() //define function getAverage().
{
return (double)sum/count; //return value
}
}
Explanation:
The above class definition can be described as:
- In the above class definition first we define a class that is " Averager". In this class we define two integer variable that is "sum and count" and assign a value that is 0. Then we define a functions :
- First we define getSum() function in this function we does not pass any value and the return type of this function is int that will return an integer value.
- Then we define add() function we use this function two times but both functions have different from each other.
- In first time implementation, we define this function and the return type of this function is void which means it does not return any value. In this function, we calculate the sum value and increase the value of the count variable by 1.
- In second time implementation, we define this function and the return type of this function is int which means it will return a value. In this function, we will return the count variable value.
- At the last, we define a getAverage() that calculates the average of the added values in the sum variable and returns its value.
Answer:
The i5.
Explanation:
It has a lower clock speed, but you do note that you have more cores, same with the cache memory.
Answer:
e.All of these are examples of information distribution
Explanation:
Information distribution can be carried out using the following means:
a. Face-To-Face Meetings
b.Telephone, e-mail, and other wireless devices
c.Web-based technologies such as video conferencing, IP Call etc.
All of these mechanisms enabled the information disseminator to communicate the information to the recipient(s).
So option (e) is the correct choice.
Answer:
For designing a database suitable for a University registrar, the following information is included which are Information about Students, Information about Departments, Information about Professors, Information about courses, Student Grades,TA's for a course, Department offering different courses.
In creating the database registrar system the following values are defined such as Entity, Attributes of entities,The relationship among entities.
Explanation:
Solution
The following requirements are for designing of database for a University registrar.
The Database Schema includes the following:
- Information about Students
- Information about Departments.
- Information about Professors.
- Information about courses.
- Student Grades.
- TA's for a course.
- Department offering different courses.
Now,
For the design of Database for Registrar System we need to define the following:
(1)Entity: Student, Course, Instructor, Course offering.
(2) Attributes of Entities:
- Student entity has Sid, name, program as its attributes
- Course has Course_n, title, credits, and syllabus as its attributes
- Instructor has iid ,name ,dept, title as its attributes
- Course offering has section_no ,time, room, year,semester as its attributes
(3) Relationship among various entities:
- Enrolls
- Teaches
- © is offered
Note: kindly find an attached copy of the E-R Diagram for University Registrar below, and his diagram shows student entity enrolls various courses which can be having teaches relationship with instructor. Course is being offered by relationship is offered by course offering.