ASM program to find the sum of squares of given ‘n’ numbers

Aim: – To write an assembly language program to find sum of squares of given ‘n’ numbers.

1
2
3
4
5
6
7
8
MOV CL, NUM
MOV SUM, 00
L1:	MOV AL, CL
MUL AL
ADD AL, SUM
MOV SUM, AL
LOOP L1
END

Result: Sum of squares of first ‘n’ natural numbers is obtained.

Chitra
Chitra

Leave a Reply

Your email address will not be published. Required fields are marked *

Get the latest updates on your inbox

Be the first to receive the latest updates from Codesdoc by signing up to our email subscription.

    StudentProjects.in