compute the daily wage of an employee.

compute the daily wage of an employee.

B. Write a JavaScript program that would input Employee Name, Rate per hour, No. of hours worked and will compute the daily wage of an employee. If the number of hours worked exceeds eight hours add 30% to each excess hours as overtime rate. Formula: Daily Wage = Rate per hour * No. of hours worked + OT pay

View Answers

December 2, 2010 at 5:38 PM

B. Write a JavaScript program that would input Employee Name, Rate per hour, No. of hours worked and will compute the daily wage of an employee. If the number of hours worked exceeds eight hours add 30% to each excess hours as overtime rate. Formula: Daily Wage = Rate per hour * No. of hours worked + OT pay


December 2, 2010 at 5:38 PM


December 2, 2010 at 5:42 PM

hi Friend,

Try the following code:

<html>
<script>
function calculate(){
var name=document.form.name.value;
var ratePerHour=document.form.rate.value;
var thours=document.form.hour.value;
var wages;
var increasedWage;
var gp;
if(thours>8){
var wage=8*ratePerHour;
var wg=wage*0.30;
var hr=thours-8;
increasedWage=wg*hr;
wages=wage+increasedWage;
}
else{
wages=thours*ratePerHour;
increasedWage=0;
}
document.writeln("Employee Name: "+name+"<br>");
document.writeln("Rate Per Hour: "+ratePerHour+"<br>");
document.writeln("No. of hours: "+thours+"<br>");
document.writeln("Overtime pay: "+increasedWage+"<br>");
document.writeln("Gross pay: "+wages+"<br>");

}
</script>
<form name="form">
<table>
<tr><td>Employee Name:</td><td><input type="text" name="name"></td></tr>
<tr><td>Rate Per Hour:</td><td><input type="text" name="rate"></td></tr>
<tr><td>Number of Hours:</td><td><input type="text" name="hour"></td></tr>
<tr><td></td><td><input type="button" value="Calcuate" onclick="calculate();"></td></tr>
</table>
</form>
</html>

Thanks









Related Tutorials/Questions & Answers:
compute the daily wage of an employee.
compute the daily wage of an employee.   B. Write a JavaScript... and will compute the daily wage of an employee. If the number of hours worked exceeds eight hours add 30% to each excess hours as overtime rate. Formula: Daily Wage
compute the daily wage of an employee.
compute the daily wage of an employee.   B. Write a JavaScript... and will compute the daily wage of an employee. If the number of hours worked exceeds... and will compute the daily wage of an employee. If the number of hours worked
Advertisements
compute
compute  B. Write a JavaScript program that would input Employee Name, Rate per hour, No. of hours worked and will compute the daily wage... hours as overtime rate. Formula: Daily Wage = Rate per hour * No. of hours
compute
Name, Rate per hour, No. of hours worked and will compute the daily wage... Name, Rate per hour, No. of hours worked and will compute the daily wage... hours as overtime rate. Formula: Daily Wage = Rate per hour * No. of hours
compute
compute    Write a menu driven program that will print out the results of the following : (1) Ceiling (2) Floor (3) Absolute (4) (a+b)^3 (5) Exit... at 25% Input the name and marks of 25 students and compute the average. Print out
ModuleNotFoundError: No module named 'daily'
ModuleNotFoundError: No module named 'daily'  Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'daily' How to remove the ModuleNotFoundError: No module named 'daily'
ModuleNotFoundError: No module named 'daily'
ModuleNotFoundError: No module named 'daily'  Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'daily' How to remove the ModuleNotFoundError: No module named 'daily'
ModuleNotFoundError: No module named 'daily'
ModuleNotFoundError: No module named 'daily'  Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'daily' How to remove the ModuleNotFoundError: No module named 'daily'
ModuleNotFoundError: No module named 'daily'
ModuleNotFoundError: No module named 'daily'  Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'daily' How to remove the ModuleNotFoundError: No module named 'daily'
Compute command
Compute command  hello, What is compute command?   hii, samarADS_TO_REPLACE_1 Compute command control computations on subsets created by the BREAK command
Adding an employee
Adding an employee  coding for adding an employee
Add Employee
Add Employee  coding for adding an employee
Employee Salaries
Employee Salaries  Define a class Employee with the following properties. Every Employee has a name and a salary. The constructor creates an Employee... the salary of the Employee to zero. The method getinfo() will return the current
ModuleNotFoundError: No module named 'daily-digest'
ModuleNotFoundError: No module named 'daily-digest'  Hi, My Python... 'daily-digest' How to remove the ModuleNotFoundError: No module named 'daily-digest' error? Thanks   Hi, In your python
ModuleNotFoundError: No module named 'daily-digest'
ModuleNotFoundError: No module named 'daily-digest'  Hi, My Python... 'daily-digest' How to remove the ModuleNotFoundError: No module named 'daily-digest' error? Thanks   Hi, In your python
ModuleNotFoundError: No module named 'daily-notes'
ModuleNotFoundError: No module named 'daily-notes'  Hi, My Python... 'daily-notes' How to remove the ModuleNotFoundError: No module named 'daily-notes' error? Thanks   Hi, In your python environment
ModuleNotFoundError: No module named 'daily-reflection'
ModuleNotFoundError: No module named 'daily-reflection'  Hi, My... named 'daily-reflection' How to remove the ModuleNotFoundError: No module named 'daily-reflection' error? Thanks   Hi, In your
ModuleNotFoundError: No module named 'daily-report'
ModuleNotFoundError: No module named 'daily-report'  Hi, My Python... 'daily-report' How to remove the ModuleNotFoundError: No module named 'daily-report' error? Thanks   Hi, In your python
ModuleNotFoundError: No module named 'daily-tweeter'
ModuleNotFoundError: No module named 'daily-tweeter'  Hi, My... 'daily-tweeter' How to remove the ModuleNotFoundError: No module named 'daily-tweeter' error? Thanks   Hi, In your python
ModuleNotFoundError: No module named 'nni-daily'
ModuleNotFoundError: No module named 'nni-daily'  Hi, My Python... 'nni-daily' How to remove the ModuleNotFoundError: No module named 'nni-daily' error? Thanks   Hi, In your python environment you
ModuleNotFoundError: No module named 'daily-digest'
ModuleNotFoundError: No module named 'daily-digest'  Hi, My Python... 'daily-digest' How to remove the ModuleNotFoundError: No module named 'daily-digest' error? Thanks   Hi, In your python
ModuleNotFoundError: No module named 'daily-notes'
ModuleNotFoundError: No module named 'daily-notes'  Hi, My Python... 'daily-notes' How to remove the ModuleNotFoundError: No module named 'daily-notes' error? Thanks   Hi, In your python environment
ModuleNotFoundError: No module named 'daily-reflection'
ModuleNotFoundError: No module named 'daily-reflection'  Hi, My... named 'daily-reflection' How to remove the ModuleNotFoundError: No module named 'daily-reflection' error? Thanks   Hi, In your
ModuleNotFoundError: No module named 'daily-report'
ModuleNotFoundError: No module named 'daily-report'  Hi, My Python... 'daily-report' How to remove the ModuleNotFoundError: No module named 'daily-report' error? Thanks   Hi, In your python
ModuleNotFoundError: No module named 'daily-tweeter'
ModuleNotFoundError: No module named 'daily-tweeter'  Hi, My... 'daily-tweeter' How to remove the ModuleNotFoundError: No module named 'daily-tweeter' error? Thanks   Hi, In your python
EMPLOYEE - SQL
EMPLOYEE  CALCULATE EMPLOYEE SALARY  Hi friend, Please give the full details of Problem. Thanks
Employee form
Employee form  In employee form emp Id id after any data iserted is incremented for oher data insertion. insert, delete, update buttons when we cleak the select buttoun then the created table data iserted automaticaly
employee records
employee records  Pl give one script like i will creat one table name Emp_master and column name like Empcode, Empname. I like one form where I... and one report like details of employee thanks
employee records
employee records  Pl give one script like i will creat one table name Emp_master and column name like Empcode, Empname. I like one form where I... and one report like details of employee thanks
employee records
employee records  Pl give one script like i will creat one table name Emp_master and column name like Empcode, Empname. I like one form where I... and one report like details of employee thanks
Employee Salaries
Employee Salaries  Define a class Employee with the following properties. Every Employee has a name and a salary. The constructor creates an Employee... the salary of the Employee to zero. The method getinfo() will return the current
Employee Salaries
Employee Salaries  Define a class Employee with the following properties. Every Employee has a name and a salary. The constructor creates an Employee... the salary of the Employee to zero. The method getinfo() will return the current
Employee Salaries
Employee Salaries  Define a class Employee with the following properties. Every Employee has a name and a salary. The constructor creates an Employee... the salary of the Employee to zero. The method getinfo() will return the current
Employee Salaries
Employee Salaries  Define a class Employee with the following properties. Every Employee has a name and a salary. The constructor creates an Employee... the salary of the Employee to zero. The method getinfo() will return the current
Employee Salaries
Employee Salaries  Define a class Employee with the following properties. Every Employee has a name and a salary. The constructor creates an Employee... the salary of the Employee to zero. The method getinfo() will return the current
application for an Employee
: in this page it should modify employee data and persist in DB 3.DISPLAY
employee progarm
employee progarm  Hai, I have developed a code for an employee program by using jtext fields and buttons,it has no errors but while we are compiling it it is saying that "Exception in thread "main
coding for employee management system
coding for employee management system  coding for employee management system
Employee Management System
Employee Management System  coding for employee management system
Employee Management System
Employee Management System  coding for employee management system
ModuleNotFoundError: No module named 'daily-google-analytics-v3'
ModuleNotFoundError: No module named 'daily-google-analytics-v3'  Hi...: No module named 'daily-google-analytics-v3' How to remove the ModuleNotFoundError: No module named 'daily-google-analytics-v3' error? Thanks  
ModuleNotFoundError: No module named 'daily-google-analytics-v3'
ModuleNotFoundError: No module named 'daily-google-analytics-v3'  Hi...: No module named 'daily-google-analytics-v3' How to remove the ModuleNotFoundError: No module named 'daily-google-analytics-v3' error? Thanks  
ModuleNotFoundError: No module named 'Daily-Reference-ET-Calculator'
ModuleNotFoundError: No module named 'Daily-Reference-ET-Calculator'  ...: No module named 'Daily-Reference-ET-Calculator' How to remove the ModuleNotFoundError: No module named 'Daily-Reference-ET-Calculator' error
ModuleNotFoundError: No module named 'lektor-mathshistory-daily'
ModuleNotFoundError: No module named 'lektor-mathshistory-daily'  Hi...: No module named 'lektor-mathshistory-daily' How to remove the ModuleNotFoundError: No module named 'lektor-mathshistory-daily' error? Thanks  
ModuleNotFoundError: No module named 'pypuppetdb_daily_report'
ModuleNotFoundError: No module named 'pypuppetdb_daily_report'  Hi...: No module named 'pypuppetdb_daily_report' How to remove the ModuleNotFoundError: No module named 'pypuppetdb_daily_report' error? Thanks   
ModuleNotFoundError: No module named 'python-daily-med'
ModuleNotFoundError: No module named 'python-daily-med'  Hi, My... named 'python-daily-med' How to remove the ModuleNotFoundError: No module named 'python-daily-med' error? Thanks   Hi, In your
ModuleNotFoundError: No module named 'python-daily-med'
ModuleNotFoundError: No module named 'python-daily-med'  Hi, My... named 'python-daily-med' How to remove the ModuleNotFoundError: No module named 'python-daily-med' error? Thanks   Hi, In your
ModuleNotFoundError: No module named 'ag-daily-reports'
ModuleNotFoundError: No module named 'ag-daily-reports'  Hi, My... named 'ag-daily-reports' How to remove the ModuleNotFoundError: No module named 'ag-daily-reports' error? Thanks   Hi, In your
ModuleNotFoundError: No module named 'daily-google-analytics-v3'
ModuleNotFoundError: No module named 'daily-google-analytics-v3'  Hi...: No module named 'daily-google-analytics-v3' How to remove the ModuleNotFoundError: No module named 'daily-google-analytics-v3' error? Thanks  
ModuleNotFoundError: No module named 'Daily-Reference-ET-Calculator'
ModuleNotFoundError: No module named 'Daily-Reference-ET-Calculator'  ...: No module named 'Daily-Reference-ET-Calculator' How to remove the ModuleNotFoundError: No module named 'Daily-Reference-ET-Calculator' error

Ads