S42BH3GKZDOFBQWMFM7V6KQWMXTHREQZZYRNAEQZWNSKXSDVTMXQC
CXBL5MVC4JXHZENYY2NKLNR4QEANSZ4CBZMTL7IGQ5MS54I5DT7AC
# Open input data file lui a0, %hi(datafile) addi a0, a0, %lo(datafile) li a1, 0 # O_RDONLY li a2, 0 li a7, 1024 # open ecall addi s2, a0, 0 # save file descriptor to s2
# Open input data file
lui a0, %hi(datafile)
addi a0, a0, %lo(datafile)
li a1, 0 # O_RDONLY
li a2, 0
li a7, 1024 # open
ecall
addi s2, a0, 0 # save file descriptor to s2
# Close input data file addi a0, s2, 0 li a7, 57 ecall
# Close input data file
addi a0, s2, 0
li a7, 57
datafile: .string "day7.txt"
datafile:
.string "day7.txt"