Results 1 to 3 of 3

Thread: Simple math

  1. #1
    Guest

    Post

    I have just got the hour using function 2c of int 21h, and the hour is in ch. Now what i want to do is find out if the hour is above 12, and if it is, subtract twelve from it, any ideas on how to do that?

  2. #2
    Lively Member
    Join Date
    Jan 2000
    Posts
    102
    what am i missing here?

    cmp ch, 12
    jb dontsub (or jl... it has been a long time)
    sub ch, 12
    dontsub:

  3. #3
    Member Cahlel's Avatar
    Join Date
    Aug 2000
    Location
    Earth (I think)
    Posts
    63
    I'm pretty sure that they both work, JB and JL that is
    Wisdom is supreme, therefore get wisdom,
    though it costs all you have, get understanding.
    Proverbs 4:7

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width