The MASM Forum Archive 2004 to 2012

General Forums => The Laboratory => Topic started by: Larry Hammick on November 10, 2009, 05:41:03 PM

Title: How to capitalize an ASCII letter
Post by: Larry Hammick on November 10, 2009, 05:41:03 PM
AND                                    AL,                                        NOT("A" XOR "a")

and don't forget to tab halfway across the screen for each new operand.
Title: Re: How to capitalize an ASCII letter
Post by: oex on November 10, 2009, 06:04:22 PM
sub al,32  ::)

Funnily enough gave me an idea for something else though...  :bg
Title: Re: How to capitalize an ASCII letter
Post by: BogdanOntanu on November 10, 2009, 06:12:33 PM
Was this post really intended for the Colosseum ?

IF the ASCII char value is already in range of A... Z THEN

OR AL,20h ; to lower case
AND AL,0DFh ; to upper case, in fact AND AL, (NOT 20h)


sorry for no TAB's
Title: Re: How to capitalize an ASCII letter
Post by: oex on November 10, 2009, 11:04:22 PM
  :lol
Title: Re: How to capitalize an ASCII letter
Post by: Larry Hammick on November 11, 2009, 05:25:01 AM
I put in in the Colosseum on the grounds that it's just a sarcastic mockery of the pedantry that we sometimes see in the software world.  :toothy IMO it has no place in the Laboratory. ::)