Defeatism or pessimism includes the assumption probably nothing I do will make any difference . Of course, when you're optimistic, you are more willing to take action to change things for the better, which increases the likelihood that things will change for the better. That's how optimism becomes self-fulfilling.
Pessimism can also become a self-fulfilling prophesy.
Optimism is not the same as thinking positively, and it is actually easier than thinking positively. But it has far more evidence from scientific experiments proving its effectiveness than positive thinking does.