Question: Part 1 : Coding task One task, two levels Regular Level Task for 1 0 0 points: Write two short assembly subroutines: one that does
Part : Coding task One task, two levels
Regular Level Task for points: Write two short assembly subroutines: one that does
bit integer division with remainder, and one that factorizes bit semiprimes.
A semiprime is simply a number that is the product of exactly two prime numbers, eg
etc. Knowing that there are exactly two prime factors makes the program or the data
structures that are required to record the factors much easier but increases running time. But
you can be smart and easily halve the running time.
The first subroutine is called integerdiv and does integer division with remainder, ie given
the operation yx where both y and x are integers, it finds the integer quotient q and the
remainder r x such that
y qx r
The integerdiv subroutine will follow this contract:
The second subroutine is called factorize and will find the two factors of a bit semiprime.
Recall a semiprime is a number that is the product of exactly two prime factors The contract
for this subroutine is as follows:
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
