You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
lettipPercent=parseFloat(tipPercentInput.value);//get tip percent value
9
9
lettotalAmount=amount*(1+tipPercent/100);//get total billing amount
10
10
lettipAmount=amount*(tipPercent/100);//get tip amount
11
-
outputText.innerText=`Total Amount: ${totalAmount.toFixed(2)}\nTip Amount: ${tipAmount.toFixed(2)}`;//set output text area to format total billing amount and tip amount
11
+
outputText.innerText=`
12
+
Total Amount: ${totalAmount.toFixed(2)}
13
+
Tip Amount: ${tipAmount.toFixed(2)}
14
+
Tip Percent: ${tipPercent}%
15
+
Bill Amount: ${amount.toFixed(2)}
16
+
`;//set output text area to format total billing amount, tip amount, tip percent and bill amount
0 commit comments