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

Home > Numbers
Four generations (Posted on 2020-07-06) Difficulty: 3 of 5
Let S be a set of all six-digit integers.

Let S1 be a subset of S, including all members of S such that each consists
of distinct digits.
Let S2 be a subset of S1, including all members of S1 each with 5 being the difference between its largest digit and its lowest one.
Let S3 be a subset of S2, comprising all elements of S2 divisible by 143.

What is the cardinality of S3 ?

Explain your way of reasoning.

No Solution Yet Submitted by Ady TZIDON    
Rating: 3.0000 (1 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
part 1 via computer | Comment 1 of 9
There are  none  Why?

lord@rabbit-3 ~ % i143       

  total cnt =            0

lord@rabbit-3 ~ more i143.f


       program i134

        implicit none

        integer cnt,i,k,kk,a,dum,dum1,d(6),maxd,mind

        cnt=0

           do 1 i=1,6993

           a=143*i

           dum=a

           mind=10

           maxd=-1

                do  k=1,6

                dum1=(dum/10)*10

                d(k)=dum-dum1

                if(d(k).lt.mind)mind=d(k)

                if(d(k).gt.maxd)maxd=d(K)

                dum=dum/10

                   if(k.gt.1)then

                        do kk=1,k-1

                        if(d(kk).eq.d(k))go to 1

                        enddo

                   endif

                enddo

           if((maxd-mind).eq.5)cnt=cnt+1

1          enddo

        print*,' total cnt = ',cnt

        end

Edited on July 6, 2020, 9:30 am
  Posted by Steven Lord on 2020-07-06 09:29:31

Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


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

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