I would like to print out "HEL" from the string "HELLO!". I am aware that I can load individual byte using lb in MIPS, however, how do I load the first 3 characters?
.data
string: .asciiz "HELLO!"
.text
lw $t6, string
lb $a0, 0-2($t6) # pseudo-code, returns "HEL"
li $v0, 4 # as opposed to 11, printing character
syscall
'L'and then using system call 4. Or just use threelbinstructions and system call 11s.