.data
title: .asciiz "/t/t高精度除法演示程序/n"
tip1: .asciiz "/n请输入被除数:"
tip2: .asciiz "请输入除数:"
tip3: .asciiz "要输出小数点后多少位:"
tip4: .asciiz "/n是否继续?(y/n)"
err: .asciiz "/n除数不能为0,请重新输入/n"
dot: .asciiz "."
sign: .asciiz "-"
buf: .byte 0:16
.text
.globl __start
__start:
#输出标题
li $v0, 4
la $a0, title
syscall
#提示输入被除数并接收输入
restart:
li $v0, 4
la $a0, tip1
syscall
li $v0, 5
syscall
move $t0, $v0