Idempotent – Related to web transactions, meaning an operation can (like a request for a dynamic page) be carried out 1 or more times without changing the result. Nullipotent means 0 or more times without changing the result. So example given, those “don’t refresh or your credit card will be charged twice” messages are neither idempotent or nullipotent.

Computer science meaning

In computer science, the term idempotent is used more comprehensively to describe an operation that will produce the same results if executed once or multiple times.[citation needed] This may have a different meaning depending on the context in which it is applied. In the case of methods or subroutine calls with side effects, for instance, it means that the modified state remains the same after the first call[citation needed]. In functional programming, though, an idempotent function is one that preserves the property f(f(x)) = f(x).[citation needed]

This is a very useful property in many situations, as it means that an operation can be repeated or retried as often as necessary without causing unintended effects. With non-idempotent operations, the algorithm may have to keep track of whether the operation was already performed or not.

Stronger is nullipotent, meaning that the results are the same if executed zero or multiple times, which is synonymous with “no side effects”.