I need to Write, assemble, and test a program that reads 2 integers n and m from the keyboard and than calculates the sum
of all "divisible by 4" numbers from the range [n,m]. This exercise requires usage of subroutine. Calculate sum in the main procedure;
Check if the number is "divisible by 4" in the subroutine.

you will learn nothing if you dont try to figuer it out by yourself. But becouse I hate getting the answer, RTFM, look at the mod or modulos fuctions.

you will learn nothing if you dont try to figuer it out by yourself. But becouse I hate getting the answer, RTFM, look at the mod or modulos fuctions.

It's realhard to think computer science i try to learn it, i still cant figure it out :(

So which bit is bugging you?

Counting between them?
Calling a function?
Getting the result from a function?
Working out if a number is divisible by 4?

If you post some effort showing what you can achieve, then ask a specific question about what to do next, or why some bit doesn't work, then you'll get a lot more help.

Most homework is layered, in that it builds on what you've done before. So if you've been paying attention and actually doing some work yourself (and not just trolling boards for free homework), then you should be able to solve some steps yourself.

you will learn nothing if you dont try to figuer it out by yourself. But becouse I hate getting the answer, RTFM, look at the mod or modulos fuctions.

my bad, i did not see this was a ASM question, dissregard my responce.

Nevermind :(

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.