当我等待减法的结果出现时,会出现这个问题,但是它会显示出0.不是x-a,因为我希望它会。 .data
strin: .asciiz "type two integers\n\n\n"
strout: .asciiz "the result of the substract is:"
a: .word 0
x: .word 1
.text
main:
li $v0,
我想了解我的CS类的MIPS汇编语言。我正努力在语法上试图编写这个程序。我看了我的教授给我们的另一个例子,我紧紧跟随它。我在我的分支上遇到了一个不对等的错误。代码如下。 # Main program that will call subroutine fib to calculate the fibonacci and
# print the result
.text
.globl main
我正在一个类项目,我想要做什么,请求theuserfor 2整数,当消息提示“请输入一个整数:”和alsoto输入一个弹出消息“请输入操作员(+,*, - ,/)”的字符。有人可以看看这个代码,并告诉我我做错了什么?第一条指令打印出来,但是我得到了一个带有字符输入的错误消息。 真的很感激 .data
prompt: .asciiz "Please enter an integer\n"
mes
如果我做了一个I/O系统调用或更多,当我完成时,我应该做一个退出调用(代码10)或不需要? 我打一个比方: .data
input_message: .asciiz "\nEnter an integer: "
.text
.globl main
main:
li $v0, 4
la $a0, input_message