Learn English – Is it appropriate to refer to a person of unknown sex by “it”

gender-neutralpronominal-agreementpronounssingular-they

I would like to treat a user as a non-gender noun and refer to it with the gender-neutral pronoun, it. E.g.,

The user defines two variables, x and y. It then multiplies each variable by a prime number.

However, on Wikipedia I found this:

The word "it", however, has an extremely impersonal connotation, even offensive, in common usage and is rarely used in English to refer to an unspecified human being or person of unknown gender. This is because the word "it" connotes that the person being specified is inferior to a person or is an object.

Is to appropriate to refer to a person of unknown sex as it?

Should I rephrase my sentence as follows:

The user defines two variables, x and y. The user then multiplies each variable by a prime number.

Best Answer

It is pejorative with reference to living beings, esp. social beings. It refers to an inanimate object.

Stay with the user throughout, for consistency, for political correctness and for consideration towards the reader.

Next, rephrase sentences to circumvent the issue of direct reference:

The user defines two variables, x and y, and then multiplies each variable by a prime number.

should do.

True, earlier some people used to refer to a newborn as it, but that is out of ignorance of the niceties. Never done in formal writing.