← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #157145]: Does the || Or Operator work with Sikuli?

 

Question #157145 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/157145

    Status: Open => Answered

RaiMan proposed the following answer:
If you mean || as a logical OR, as in other languages - this is not
defined in Python.

You have to use "or" for this:

if exists(img1) or exists(img2):
    click(getLastMatch())

-- 
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.