Path: utzoo!mnetor!uunet!lll-winken!lll-lcc!ames!ucsd!sdcsvax!ucsdhub!hp-sdd!hplabs!otter!sjmz From: sjmz@otter.hple.hp.com (Stefek Zaba) Newsgroups: comp.unix.wizards Subject: Re: ATTN: AWK GURUS!!! (lower to upper conversion) Message-ID: <1590004@otter.hple.hp.com> Date: 22 Mar 88 14:54:46 GMT References: <16782@beta.UUCP> Organization: Hewlett-Packard Laboratories, Bristol, UK. Lines: 8 Make no apology! Your lookup table is a perfectly neat solution given the wierd constraints you've acquired. Personally I'd even avoid the "if lc-alpha" test, and construct a table with the full 128 (sorry, non-USASCII users!) characters, using an awk FOR with printf %c, and then overwrite the 26 elements of interest. This avoids the "if" in your inner loop (though maybe awk table lookup is slow enough to make the "if" test a win in efficiency, if not clarity.) Keep at it - awk's clearly Turing-complete! (**Please**, no TM's-in-awk!!!)