Below is an instruction that describes a task. Write a response that appropriately completes the request.

### Instruction:
Compute the value of the function y=x^2-2x+1 when x=2

### Response:
The value of y when x=2 is 1.