Possible Duplicate:
“If I was” or “If I were”. Which is more common, and which is correct?

Should I say "If I were [something]" or "If I was [something]?"

This came up because I am writing a comment above a function in some code. Here's the comment, basically:

// Shuts down everything
// Will stop the process if it was running
function Shutdown()

So should that say "if it was running" or "if it were running?"

Also, why?


1 Answer 1


In your specific case, neither 'was' nor 'were' is best; you should say "if it is running".

"If it were running" is subjunctive case, used to describe hypothetical situations: "If it were running, I would stop it first, but it's already stopped."

"If it was running" is a common corruption of subjunctive case, or, as described in the other questions, a way to express an option that occurred in the past. In this case, using a continuous-action verb feels inappropriate; a discrete-action verb would fit better: "If it was started, then we need to stop it."

Since you are describing a possible situation that exists in the present, though, the present tense is best. "If it is running, stop it."

  • I have a sentence from a news paper, it says: "At the time Musk said that the development of the prototype could take one or two years if it was his top priority." This sentence doesn't follow your 'rule in second paragraph'. Please explain it. Thanks
    – Kalvaniya
    Dec 21, 2017 at 7:58

Not the answer you're looking for? Browse other questions tagged or ask your own question.