MathGroup Archive 2003

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: List in base 16

  • To: mathgroup at smc.vnet.net
  • Subject: [mg40175] Re: List in base 16
  • From: Dr Bob <drbob at bigfoot.com>
  • Date: Tue, 25 Mar 2003 03:03:18 -0500 (EST)
  • References: <200303240928.EAA28675@smc.vnet.net>
  • Reply-to: drbob at bigfoot.com
  • Sender: owner-wri-mathgroup at wolfram.com

toHex = Characters["0123456789ABCDEF"][[# + 1]] &;
hexDigits = toHex /@ IntegerDigits[#, 16] &;
hexString = StringJoin @@ hexDigits@# &;

BaseForm[Prime[100], 16]
hexDigits[Prime[100]]
hexString@Prime@100

Bobby

On Mon, 24 Mar 2003 04:28:40 -0500 (EST), Steve Gray <stevebg at adelphia.net> 
wrote:

> 	BaseForm uses lower case letters and prints the subscript 16
> after each number. Is there a way to print a list whose elements are
> integers 0 through 15 using 0,1,...,9,A,B,C,D,E,F without the
> subscript 16? E.g. {8,13,11,3} should appear as {8,D,B,3}.
> 	Help will be appreciated. Thank you.
>
>
>



-- 
majort at cox-internet.com
Bobby R. Treat



  • Prev by Date: Re: Plot a recurrence relation
  • Next by Date: DSolve and N do not commute
  • Previous by thread: List in base 16
  • Next by thread: Re: List in base 16