Code to generate a sign wave

Code:

x := x + 2;
IF x > 360 THEN x := 0; END_IF;
y := INT_TO_REAL(x) * 0.01745329;
answer := SIN(y) * 100;