RUVIDEO
Поделитесь видео 🙏

PayCalculator for full-time and part-time employees in java

In this video, a pay calculator is created in Netbeans IDE, as the requirements of this program are described below:

(Turn on caption for detail)

Program Name: PayCalculator

A corporation named XYZ needs a program to calculate how much to pay their part-time and full-time employees.
For full-time employees, employees get paid time and a half for any hours over 40 that they work in a single week. For example, if an employee works 45 hours, they get 5 hours of overtime, at 1.5 times their base pay. The base should be at least RS. 120 an hour. This XYZ Corporation requires that an employee not work more than 60 hours a week.

For part-time employees, they get paid time and a half for any hours over 30 that they work in a single week. For example, if an employee works 33 hours, they get 3 hours of overtime, at 1.5 times their base pay. Their base pay should not be less than RS. 110 an hour. This XYZ Corporation requires that an employee not work more than 35 hours a week.

To sum up:
• An employee gets paid (hours worked) × (base pay) for each hour up to 30 or 40 hours depending upon employee type.
• For every hour over 30 or 40 depending upon employee type, they get overtime = Overtime hours × (base pay) × 1.5.
• The base pay must not be less than the minimum wage (RS. 110 or RS. 120 an hour depending upon employee type).
• The working hours must not exceed 35 or 60 depending upon employee type.


Write a program that asks the user to enter Employee Name, Employee type (full-time/part-time), working hours, and base pay. You need to write the following methods:


1. Write a method that validates the input that if it is in a given range or not.

public static boolean isValidInput(char empType, int workingHours, double basePay)


2. A method that calculates pay based on given parameters.

public static double calculatePay(char empType, int workingHours, double basePay)


3. A method to calculate overtime pay. This method should be called from calculatePay if and when required.

public static double calculateOverTimePay(int overTimeHours, double basePay)


4. A method to display information

public static void displayInfo(String empName, int workingHours, double totalPay)

Что делает видео по-настоящему запоминающимся? Наверное, та самая атмосфера, которая заставляет забыть о времени. Когда вы заходите на RUVIDEO, чтобы посмотреть онлайн «PayCalculator for full-time and part-time employees in java», вы рассчитываете на нечто большее, чем просто загрузку плеера. И мы это понимаем. Контент такого уровня заслуживает того, чтобы его смотрели в HD 1080, без дрожания картинки и бесконечного буферизации.

Честно говоря, Rutube сегодня — это кладезь уникальных находок, которые часто теряются в общем шуме. Мы же вытаскиваем на поверхность самое интересное. Будь то динамичный экшн, глубокий разбор темы от любимого автора или просто уютное видео для настроения — всё это доступно здесь бесплатно и без лишних формальностей. Никаких «заполните анкету, чтобы продолжить». Только вы, ваш экран и качественный поток.

Если вас зацепило это видео, не забудьте взглянуть на похожие материалы в блоке справа. Мы откалибровали наши алгоритмы так, чтобы они подбирали контент не просто «по тегам», а по настроению и смыслу. Ведь в конечном итоге, онлайн-кинотеатр — это не склад файлов, а место, где каждый вечер можно найти свою историю. Приятного вам отдыха на RUVIDEO!

Видео взято из открытых источников Rutube. Если вы правообладатель, обратитесь к первоисточнику.