ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   if formulas (https://www.excelbanter.com/excel-discussion-misc-queries/72261-if-formulas.html)

lestie

if formulas
 
i need help w/a formula

if hours<= 40, then gross pay=rate*hours, otherwise gross
pay=rate*hours+0.5* rate*(hours-40)

cell b4 rate
cell c4 hours

next
if(gross pay-dependents*38.46)0, then federal tax=20%*(gross
pay-dependents*38.46), otherwisw federal tax=0

cell f4 gross pay
cell d4 dependents
cell i4 fed tax

--
lestie

[email protected]

if formulas
 
"lestie" wrote:
if hours<= 40, then gross pay=rate*hours, otherwise gross
pay=rate*hours+0.5* rate*(hours-40)
cell b4 rate
cell c4 hours


A couple of several ways to do it:

=b4*c4 + max(0, 0.5*b4*(c4-40))
=b4*c4 + if(c4<=0, 0, 0.5*b4*(c4-40))

if(gross pay-dependents*38.46)0, then federal tax=20%*(gross
pay-dependents*38.46), otherwisw federal tax=0
cell f4 gross pay
cell d4 dependents
cell i4 fed tax


In I4, one of the following (among others):

=max(0, 20%*(f4 - d4*38.46))
=if(f4 - d4*38.46 <= 0, 0, 20%*(f4 - d4*38.46))

Dsuperc

if formulas
 
try this site.
http://www.personal-computer-tutor.com/if2.htm

"lestie" wrote:

i need help w/a formula

if hours<= 40, then gross pay=rate*hours, otherwise gross
pay=rate*hours+0.5* rate*(hours-40)

cell b4 rate
cell c4 hours

next
if(gross pay-dependents*38.46)0, then federal tax=20%*(gross
pay-dependents*38.46), otherwisw federal tax=0

cell f4 gross pay
cell d4 dependents
cell i4 fed tax

--
lestie



All times are GMT +1. The time now is 07:21 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com