masm
mov ecx,10;assuming you want the sum till ten terms
mov eax,2
mov ebx,0
mov edx,0
begin:
push edx
inc ebx
mul ebx
pop edx
add edx,eax
loop begin
finally edx holds the value
What do you mean?
You could write a simple program in java to do this like so;
class apples {
public static void main(String args[]){
System.out.println(2+4+6+8+10+11+12+13+15+17);
}
You can test this out here;
http://www.browxy.com/
Copyright © 2024 QUIZLS.COM - All rights reserved.
Answers & Comments
Verified answer
mov ecx,10;assuming you want the sum till ten terms
mov eax,2
mov ebx,0
mov edx,0
begin:
push edx
inc ebx
mul ebx
pop edx
add edx,eax
loop begin
finally edx holds the value
What do you mean?
You could write a simple program in java to do this like so;
class apples {
public static void main(String args[]){
System.out.println(2+4+6+8+10+11+12+13+15+17);
}
}
You can test this out here;
http://www.browxy.com/