Numerical puzzle, №4

Logic Level 3

A + B × ( C + D ) + E × ( F × ( G + H ) + I ) \overline{\textcolor{#D61F06}{A}}+\overline{\textcolor{#20A900}{B}}\times\left({\overline{\textcolor{#3D99F6}{C}}+\overline{\textcolor{#EC7300}{D}}}\right)+\overline{\textcolor{#69047E}{E}}\times\left({\overline{\textcolor{#333333}{F}}\times\left({\overline{\textcolor{grey}{G}}+\overline{\textcolor{#E81990}{H}}}\right)+\overline{\textcolor{#BA33D6}{I}}}\right) All numbers from n {n} to m {m} can be represented as sum above, where A , B , , H , I \textcolor{#D61F06}{A},\textcolor{#20A900}{B},\dots,\textcolor{#E81990}{H},\textcolor{#BA33D6}{I} are distinct digits. What is maximal value of m n m-n ?


The answer is 993.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

1 solution

r = Union [ Table [ { a , b , c , d , e , f , g , h , i } = p ; a + b ( c + d ) + e ( f ( g + h ) + i ) , { p , Permutations [ Range [ 0 , 9 ] , { 9 } ] } ] ] ; Last [ r ] First [ r ] 993 r=\text{Union}[\text{Table}[\{a,b,c,d,e,f,g,h,i\}=p;a+b (c+d)+e (f (g+h)+i),\{p,\text{Permutations}[\text{Range}[0,9],\{9\}]\}]];\text{Last}[r]-\text{First}[r]\Rightarrow 993

English translation: Compute a list of all values of the expression while iterating over all permutations of integers from 0 to 9 inclusive taken 9 integer at a time, reduce the list to a sorted set of values and subtract the first value from the last value.

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...