MathGroup Archive 2010

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

Search the Archive

Re: create character listing

  • To: mathgroup at smc.vnet.net
  • Subject: [mg112572] Re: create character listing
  • From: Themis Matsoukas <tmatsoukas at me.com>
  • Date: Mon, 20 Sep 2010 05:44:19 -0400 (EDT)

(*make ascii list of alphabet*)
CodeList=Range[97, 122];

(*calculate all 3-letter combinations in ASCII form (17576 in total)*)
CodeList3=Tuples[CodeList, 3];

(*turn 3-ASCII codes into 3-letter strings*)
LetterList=Thread[FromCharacterCode[CodeList3]];

(*find the location of "bzz"*)
ibzz=Flatten[Position[LetterList, "bzz"]][[1]];

(*print elements "aaa" thru "bzz" -- that's 1352 elements*)
TableForm[Table[LetterList[[i]], {i, 1, ibzz}]]

Themis


  • Prev by Date: Mathematica Journal freely accessible
  • Next by Date: Re: Contraction of Tensors in Mathematica
  • Previous by thread: Re: create character listing
  • Next by thread: Re: create character listing