Assuming you're talking about DOS / Windows batch files, I think you want something like this:
SET do_stuff=false
IF EXIST file1 IF EXIST file2 SET do_stuff=true
IF "%do_stuff%"=="true" (
REM do stuff
) ELSE (
REM do something else
)
, DOS if / , if ( then else), , if ( ). , . , .:)
(SO, ), , (help if if /? IIRC).