
the given code is:
#name:
#studentID:
.data
#Must use accurate file path.
#file paths in MARS are relative to the mars.jar file.
# if you put mars.jar in the same folder as test2.txt andyour.asm, input: should work.
input: .asciiz “test2.txt” #used as input
output: .asciiz “copy.pgm” #used as output
buffer: .space 2048 # buffer for upto 2048 bytes
.text
.globl main
main:
la $a0,input #readfile takes $a0 as input
jal readfile
la $a0, output #writefile will take $a0 as file location
la $a1,buffer #$a1 takes location of what we wish to write.
jal
PayPal Gateway not configured
PayPal Gateway not configured