Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

3. Write a program that calculates the average number of days a company employee is absent. The program should have the following three methods: .A

image text in transcribed
3. Write a program that calculates the average number of days a company employee is absent. The program should have the following three methods: .A method that asks the user for number of employees in the company. Thi is value should be returned as an int type value. The method accepts no arguments. A method that accepts one argument: the number of employees in the company. The method should ask the user to enter the number of days each employee missed during the past year. The total of these days should be returned as int type. (you need to use a loop to find this total) . A method that accepts two arguments: The number of employees in the company and the total number of days absent for all employees during the past year. The method should return, as double type, the average number of days absent. (This method does not perform screen output and does not ask the user for input). Use appropriate description phrases with the output

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions