Texts:
Q1) Write 1 line of MIPS Assembly code so that: $s2 = 192 (decimal)
Answer: li $s2, 192
Q2) Write 1 line of assembly code in front of each comment (comment is the instruction):
Answer:
addi $s2, $zero, 118 # $s2 = 118 (decimal)
and $s2, $s2, 0xecba # Do $s2 = $s2 and 0xecba
# result of the last instruction: $s2 = _________ (hexadecimal)
Q3) Write 1 line of assembly code in front of each comment:
Answer:
li $s1, 0x2179 # $s1 = 0x2179 (hexadecimal)
or $s1, $s1, 0x3bcd # Do $s1 = $s1 or 0x3bcd
# result of the last instruction: $s1 = 0x________ (hexadecimal)