Files
2026-10-05 01:25:54 +03:00

20 lines
464 B
ArmAsm
Raw Permalink Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Напишите программу на ассемблере RISC-V ,
# которая принимает на вход целое число x и выводит 1,
# если оно соответствует номеру студента в списке группы
# и  0, если не совпадает.
.text
.globl main
main:
li a7, 5
ecall
addi a0, a0, -3
seqz a0, a0
li a7, 1
ecall
exit:
li a7, 10
ecall