a = nil b = nil c = nil d = 1 n = 0 if not a or b and n == 1 and not c and d > 0 print "1) yup\n" end if not a or (b and n == 1 and not c and d > 0) print "2) yup\n" end if not a || b && n == 1 && !c && d > 0 print "3) yup\n" end の結果が 2) yup 3) yup になる理由がわからないのですが。 n=1だと1)もyupになります。 これで1時間くらい苦闘してしまった。 怪しいときは括弧でくくれですかねえ。 -- 人生を背負い投げ 菊谷 誠(Kikutani Makoto) kikutani / sprintmail.com