Discussion:
the multiplying program
(too old to reply)
[Instr] Albert Chae
2008-08-03 21:40:30 UTC
Permalink
Raw Message
You can treat them as unsigned numbers. Also, don't worry about
the result overflowing.

Albert
can the two words in memory correspond to negative numbers? or will they be
positive numbers? i.e. are we gonna have a case like -2 x -2 or -2 x 2 ?
thanks
Maan
[Instr] Albert Chae
2008-08-03 23:55:08 UTC
Permalink
Raw Message
No.. I guess not. It should still work on 15 bit unsigned numbers right?

Albert
Ok, I did write a program that multiplies the two as signed. So, do i have to
go back and write another one
Post by [Instr] Albert Chae
You can treat them as unsigned numbers. Also, don't worry about
the result overflowing.
Albert
can the two words in memory correspond to negative numbers? or will they be
positive numbers? i.e. are we gonna have a case like -2 x -2 or -2 x 2 ?
thanks
Maan
[Instr] Albert Chae
2008-08-03 23:58:30 UTC
Permalink
Raw Message
Yes, we are ignoring overflow.
yes, if you ignore overflow
Post by [Instr] Albert Chae
No.. I guess not. It should still work on 15 bit unsigned numbers right?
Albert
Ok, I did write a program that multiplies the two as signed. So, do i have
to
Post by [Instr] Albert Chae
go back and write another one
Post by [Instr] Albert Chae
You can treat them as unsigned numbers. Also, don't worry about
the result overflowing.
Albert
can the two words in memory correspond to negative numbers? or will they
be
Post by [Instr] Albert Chae
Post by [Instr] Albert Chae
positive numbers? i.e. are we gonna have a case like -2 x -2 or -2 x 2
?
Post by [Instr] Albert Chae
Post by [Instr] Albert Chae
thanks
Maan
Loading...