What's new

Employee salary system

bryanpogi_10

Grasshopper
Joined
Nov 24, 2021
Posts
1
Reaction
0
Points
12
computation of salary the program can compute the salary of employee in rate 500 per day and OT 100 and allowance 50 per day find the total gross and the total deduction and the net pay of the employee pano po yan salamat po
 
Ako na namili ng language TS 🤣

HTML:
<!DOCTYPE html>
<html>
<body>
<p>Your salary: <span id="salary"></span></p>
<script>
var daily_rate = 500;
var ot_rate = 100;
var allowance_rate = 50;

var days_work = 2;
var days_ot = 1;

function compute_salary() {
  return (days_work * daily_rate) + (days_ot * ot_rate) + (days_work * allowance_rate);
}
document.getElementById("salary").innerHTML = compute_salary();
</script>
</body>
</html>
 

Similar threads

Back
Top