I think it's =IF(C1, 1, IF(,,)) -- I got it from another stack overflow thread, but I can't find the link to it now, sorry :(