All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > General > Word Problems
X-pandigital Words (Posted on 2012-11-07) Difficulty: 2 of 5
Let us define an x-pandigital word, where A=1,B=2,C=3, etc., as an English word such that the concatenated digits 0 to x of the positional letter-values are used exactly once. In order for a word to be a true x-pandigital word all digits between 0 and x, and only digits 0 to x, must be used exactly once.
What are the shortest and longest x-pandigital words*?

A zeroless x-pandigital word is a word with the same constraints as an x-pandigital word, but excludes the digit 0. What are the shortest and longest zeroless x-pandigital words?

*More than one possible word may exist for both shortest and longest. The length of an x-pandigital word can be less or equal to length x. As such, an x-pandigital word that uses more digits is considered longer for words otherwise of the same length.
You may provide as many x-pandigital words you find, even those that are neither the smallest or largest. An example of an x-pandigital word where x=5 is CENT {C=3, E=5, N=14, T=20}. The concatenated value of CENT is 351420, composed of the digits (not numbers) 0 thru 5.

See The Solution Submitted by Dej Mar    
No Rating

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution computer solutions | Comment 1 of 3

OPEN "\words\words.txt" FOR INPUT AS #1
OPEN "xpandigw.txt" FOR OUTPUT AS #2
DO
    INPUT #1, w$
    good = 1: n$ = ""
    FOR i = 1 TO LEN(w$)
      p = INSTR("abcdefghijklmnopqrstuvwxyz", MID$(w$, i, 1))
      IF p = 0 THEN good = 0: EXIT FOR
      n$ = n$ + LTRIM$(STR$(p))
    NEXT
    IF good THEN
       REDIM used(9)
       FOR i = 1 TO LEN(n$)
         used(VAL(MID$(n$, i, 1))) = 1
       NEXT
       IF used(0) = 0 THEN good = 0
       flag = 1
       FOR i = 0 TO 9
          IF used(i) = 0 THEN flag = 0
          IF used(i) = 1 AND flag = 0 THEN good = 0: EXIT FOR
       NEXT
       IF good THEN
          x = 9
          FOR i = 0 TO 9
            IF used(i) = 0 THEN x = i - 1: EXIT FOR
          NEXT
          PRINT w$, x
          PRINT #2, USING "# ## ## & &"; x; LEN(w$); LEN(n$); w$; n$
          IF LEN(w$) > LEN(longest$) THEN
            longlen = LEN(w$)
            longxval = x
            longest$ = w$
            ln$ = n$
          END IF
       END IF
    END IF
LOOP UNTIL EOF(1)
PRINT
PRINT longest$, longlen, longxval, ln$
CLOSE

finds 2120 x-pandigital words for the various values of x.

An abbreviated list (sorted) follows to show shortest and longest, with sufficient margin to allow you to judge whether a given word is "common" enough to be allowed:

With zeroes:

    len
x wrd num word and numeric value
2  2  3 at 120
2  2  3 ta 201
2  2  4 ut 2120
2  3  4 bat 2120
2  3  4 jab 1012
2  3  4 tab 2012
...
2  5  9 butut 221202120
2  5  9 taluk 201122111
2  5  9 vault 221211220
2  6  8 albata 11221201
2  6  8 atabal 12012112
2  6  8 balata 21121201
2  6  9 ablaut 121212120
2  6 10 atlatl 1201212012
2  6 10 taluka 2011221111
2  6 10 valuta 2211221201
2  7 11 abuttal 12212020112
2  7 11 bullbat 22112122120

3  3  4 act 1320
3  3  4 cat 3120
3  3  5 cut 32120
3  3  5 jaw 10123
3  3  5 mat 13120
3  3  5 tam 20113
3  3  5 taw 20123
...
3  7 10 catcall 3120311212
3  7 10 catclaw 3120312123
3  7 10 cutback 3212021311
3  7 10 tambala 2011321121
3  7 11 catwalk 31202311211
3  7 11 tactual 20132021112
3  7 12 jumbuck 102113221311
3  8 12 backtalk 213112011211
3  9 13 blackjack 2121311101311
3  9 13 matambala 1312011321121

4  4  6 cant 311420
4  4  6 dawt 412320
4  4  6 duct 421320
4  4  7 **** 3211420
4  4  7 want 2311420
...
4  8 11 amadavat 11314122120
4  8 12 tamandua 201131144211
4  8 13 ambulant 1132211211420
4  8 14 autumnal 12120211314112
4  8 14 tantalum 20114201122113
4  9 14 attackman 12020131113114

5  4  6 cent 351420
5  4  7 newt 1452320
5  4  7 went 2351420
5  4  8 nowt 14152320
5  4  8 town 20152314
5  4  8 wont 23151420
...
5 13 20 nonattendance 14151412020514411435
5 13 20 unaccountable 21141331521142012125
5 13 21 mononucleated 131514151421312512054
5 13 21 unaccountably 211413315211420121225
5 13 23 monocotyledon 13151415315202512541514
5 14 21 unaccommodated 211413315131315412054
5 14 22 nonaccountable 1415141331521142012125
5 14 23 malcontentedly 13112315142051420541225

6  6  8 wafted 23162054
6  6  9 except 524351620
6  6  9 expect 524165320
6  6  9 pecten 165320514
6  6  9 tamped 201131654
6  6  9 temped 205131654
6  6 10 exempt 5245131620
6  6 10 fantom 6114201513
6  6 10 foment 6151351420
6  6 10 jumped 1021131654
6  6 10 tumped 2021131654
6  6 11 potman 16152013114
6  6 11 potmen 16152013514
6  6 11 tampon 20113161514
6  6 11 tympan 20251316114
6  6 11 unwept 21142351620
6  6 12 uptown 211620152314
...
6 13 19 nonacceptance 1415141335162011435
6 13 21 bamboozlement 211321515261251351420
6 13 21 developmental 452251215161351420112
6 13 21 fundamentally 621144113514201121225
6 13 22 nonconceptual 1415143151435162021112
6 13 23 pneumonectomy 16145211315145320151325
6 13 24 nonemployment 141514513161215251351420
6 14 23 uncontemplated 21143151420513161212054
6 14 24 nondevelopment 141514452251215161351420
6 15 25 developmentally 4522512151613514201121225

7  9 13 genuflect 7514216125320
7 10 15 neglectful 145712532062112
7 10 16 engulfment 5147211261351420
7 10 16 zygodactyl 2625715413202512
7 11 15 genuflected 751421612532054
7 12 19 neglectfully 1457125320621121225
7 12 21 pneumatology 161452113120151215725
 (this is the complete list for x=7)
 
8  8 12 fragment 618171351420 
8  9 14 pentagram 16514201718113
...
8 20 30 electroencephalogram 512532018155143516811215718113
8 21 31 electroencephalograph 5125320181551435168112157181168
8 22 33 electroencephalography 512532018155143516811215718116825
8 23 34 electroencephalographer 5125320181551435168112157181168518

9  8 10 fetching 6520389147
9  8 14 tromping 20181513169147
9  9 12 fletching 612520389147
9  9 12 refecting 185653209147
9  9 13 carpeting 3118165209147
9  9 13 factoring 6132015189147
9  9 13 fathoming 6120815139147
9  9 13 preacting 1618513209147
9  9 14 fragments 61817135142019
9  9 14 sceptring 19351620189147
9  9 14 tampering 20113165189147
9  9 14 tempering 20513165189147
9  9 15 frowsting 618152319209147
9  9 15 importing 913161518209147
9  9 15 permuting 165181321209147
9  9 16 promoting 1618151315209147
9  9 16 prompting 1618151316209147
...
9 21 30 electrocardiographies 512532018153118491571811689519
9 21 30 meningoencephalitides 135149147155143516811292094519
9 21 32 antiferromagnetically 11420965181815131714520931121225
9 21 32 clinicopathologically 31291493151612081512157931121225
9 21 32 electroencephalograms 51253201815514351681121571811319
9 21 32 electroretinographies 51253201815185209141571811689519
9 21 33 overintellectualizing 152251891420512125320211129269147
9 21 33 straightforwardnesses 192018197820615182311841451919519
9 22 33 electroencephalographs 512532018155143516811215718116819
9 23 33 electroencephalographic 512532018155143516811215718116893
9 24 35 electrocardiographically 51253201815311849157181168931121225
9 24 35 electroencephalographies 51253201815514351681121571811689519
9 24 36 electroencephalographers 512532018155143516811215718116851819


Without zeroes (using a slightly different program, finding 2420 words in all):

 
1  1  1 a 1
1  2  2 aa 11
1  2  3 ka 111
1  4  6 kaka 111111
 (this is the complete list for x=1)
 
2  2  2 ab 12
2  2  2 ba 21
2  2  3 al 112
2  2  3 la 121
2  3  3 aba 121
2  3  3 baa 211
2  3  4 aal 1112
2  3  4 ala 1121
2  3  4 alb 1122
2  3  4 ava 1221
...
2  7  9 kabbala 111221121
2  7 10 baklava 2111121221
2  7 12 valvula 221122221121
2  8 12 kavakava 111221111221
2  8 12 lavalava 121221121221
3  2  3 aw 123
3  2  4 mu 1321
3  2  4 um 2113
3  3  3 cab 312
3  3  4 awa 1231
3  3  4 bam 2113
3  3  4 caw 3123
3  3  4 cub 3212
3  3  4 lac 1213
3  3  4 vac 2213
3  3  4 wab 2312
3  3  5 amu 11321
3  3  5 awl 12312
3  3  5 bum 22113
3  3  5 cum 32113
3  3  5 cwm 32313
3  3  5 lam 12113
3  3  5 law 12123
3  3  5 maw 13123
3  3  5 vaw 22123
3  3  5 waw 23123
3  3  6 lum 122113
3  3  6 mum 132113
3  3  6 umm 211313
...
3  8 10 maccabaw 1313312123
3  8 11 callback 31121221311
3  8 14 muckluck 13213111221311
3  9 12 balaclava 211213121221
3  9 13 blackball 2121311211212
3  9 15 muckamuck 132131111321311
 
4  3  4 cud 3214
4  3  4 daw 4123
4  3  4 wad 2314
4  3  5 awn 12314
4  3  5 max 13124
4  3  5 mud 13214
4  3  5 naw 14123
4  3  5 wan 23114
4  3  5 wax 23124
4  3  5 wud 23214
4  3  6 mun 132114
...
4  8 11 backland 21311121144
4  8 12 labdanum 121241142113
4  8 13 duckwalk 4213112311211
4  8 13 laudanum 1212141142113
4  9 12 balmacaan 211213131114
4  9 13 blackland 2121311121144
 
5  3  5 cox 31524
5  3  5 dow 41523
5  3  5 new 14523
5  3  5 wen 23514
5  3  6 now 141523
5  3  6 own 152314
5  3  6 won 231514
5  3  6 wyn 232514
...
5 12 18 cannonballed 311414151421121254
5 12 18 downloadable 415231412151412125
5 12 19 mollycoddled 1315121225315441254
5 12 19 nonmalleable 1415141311212512125
5 13 19 noncancelable 1415143114351212125
 
6  5  7 fancy 6114325
6  5  7 fumed 6211354
6  5  7 mazed 1312654
6  5  7 pawed 1612354
6  5  8 cozen 31526514
6  5  8 fawny 61231425
6  5  8 umped 21131654
...
6 12 16 backpedalled 2131116541121254
6 12 17 codependency 31545165144514325
6 12 19 compoundable 3151316152114412125
6 12 19 confoundedly 3151461521144541225
6 12 19 nonflammable 1415146121131312125
6 12 19 pneumococcal 1614521131531533112
6 12 19 unconfounded 2114315146152114454
6 12 20 uncompounded 21143151316152114454
6 12 20 unemployable 21145131612152512125

7  6  8 gawped 71231654
7  7 10 flagmen 6121713514
7  7 10 pawnage 1612314175
7  7 11 pygmean 16257135114
7  7 12 zymogen 262513157514
...
7 11 15 camouflaged 311315216121754
7 11 18 campanology 311316114151215725
 
8  7 11 grumped 71821131654
8  7 12 gumdrop 721134181516
8  7 13 grownup 7181523142116
8  7 13 upgrown 2116718152314
8  8 14 wrongful 23181514762112
...
8 14 20 encephalograph 51435168112157181168
8 14 23 overprogrammed 15225181618157181131354
8 14 23 unprogrammable 21141618157181131312125
8 14 24 gynandromorphy 725141144181513151816825
8 15 22 encephalography 5143516811215718116825
8 15 22 unchoreographed 2114381518515718116854
8 15 26 lymphogranuloma 12251316815718114211215131
8 17 28 neuropharmacology 1452118151681181313151215725
 
9  8 10 grecized 7185392654
9  8 11 wafering 23165189147
9  8 11 wheeping 23855169147
9  8 11 wheezing 23855269147
9  8 12 cognizer 315714926518
9  8 12 forewing 615185239147
9  8 12 pouching 161521389147
9  8 12 psyching 161925389147
9  8 12 whelping 238512169147
9  8 12 whoofing 238151569147
9  8 12 zorching 261518389147
9  8 13 frowning 6181523149147
9  8 13 impugner 9131621714518
9  8 13 powering 1615235189147
9  8 13 whomping 2381513169147
9  8 13 whooping 2381515169147
9  8 13 whopping 2381516169147
9  8 14 gumdrops 72113418151619
9  8 14 prowling 16181523129147
9  8 15 grownups 718152314211619
...
9 18 26 videoconferencings 22945153151465185143914719
9 18 27 lymphangiographies 122513168114791571811689519
9 18 28 neuropharmacologic 1452118151681181313151215793
9 18 29 neurophysiological 14521181516825199151215793112
9 18 29 neuropsychological 14521181516192538151215793112
9 18 29 phenomenologically 16851415135141512157931121225
9 18 31 uncompromisingness 2114315131618151391991471451919
9 19 29 overcommercializing 15225183151313518391129269147
9 19 30 neuropharmacologies 145211815168118131315121579519
9 20 31 neuropharmacological 1452118151681181313151215793112
9 20 33 neurophysiologically 145211815168251991512157931121225
9 20 34 uncompromisingnesses 2114315131618151391991471451919519
9 21 31 phosphoglyceraldehyde 1681519168157122535181124582545
9 22 33 phosphoglyceraldehydes 168151916815712253518112458254519

  Posted by Charlie on 2012-11-07 14:53:32
Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


Search:
Search body:
Forums (1)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (12)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2024 by Animus Pactum Consulting. All rights reserved. Privacy Information