Consider the following MIPS assembly code snippet:
```assembly
.data
array: .word 3, 7, 1, 9, 2
.text
main:
# Your code here
```
Write MIPS assembly code to find the maximum value in the array and store it in the register `$t0`. After your code, assume that the value in register `$t0` contains the maximum value.
Remember to follow the MIPS conventions and use appropriate registers for temporary storage.