Münchhausen Number

Author

Eric W. Weisstein
January 25, 2012

This notebook downloaded from http://mathworld.wolfram.com/notebooks/IntegerSequences/MuenchhausenNumber.nb.

For more information, see Eric's MathWorld entry http://mathworld.wolfram.com/MuenchhausenNumber.html.

©2011 Wolfram Research, Inc. except for portions noted otherwise

Code

MunchausenQ[n_]:=Total[#^#&/@DeleteCases[IntegerDigits[n],0]]==n

Compute

MunchausenQ/@{0,1,3435,438579088}

Select[Range[10^6],MunchausenQ]//Timing

Select[Range[10^7],MunchausenQ]//Timing

Select[Range[10^8],MunchausenQ]//Timing

Select[Range[10^9],MunchausenQ]//Timing