5312 ÷ 9 = 590 R2
We're going to perform division on 5312 with 9 as the divisor.

Step 1:
9 goes into 5 0 times with a remainder of 5.
Write down 0 as next digit of of the result. 
Result so far: 0
Subtract 0 from 5 to get 5.
Bring next digit (3) of the dividend behind the 5 and repeat the process: 53 / 9

Step 2:
9 goes into 53 5 times with a remainder of 8.
Write down 5 as next digit of of the result. 
Result so far: 5
Subtract 45 from 53 to get 8.
Bring next digit (1) of the dividend behind the 8 and repeat the process: 81 / 9

Step 3:
9 goes into 81 9 times with a remainder of 0.
Write down 9 as next digit of of the result. 
Result so far: 59
Subtract 81 from 81 to get 0.
Bring next digit (2) of the dividend behind the 0 and repeat the process: 2 / 9

Step 4:
9 goes into 2 0 times with a remainder of 2.
Write down 0 as next digit of of the result. 
Result so far: 590
Subtract 0 from 2 to get 2.

The final result is 590 with a remainder of 2.