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

Home > Numbers
2 absent digits (Posted on 2020-11-28) Difficulty: 2 of 5
The product of 722*227 (163,894) contains neither 2 nor 7. List all the couples (b,c; b>c) such that the product bcc*ccb contains neither b nor c. Bonus: From the above list select couples, if any, using none of the corresponding digits in the partial products as well.

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

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution also solved | Comment 2 of 6 |
Also solved, same solution as Steven Lord.

b c bcc ccb  b*c
3 2 322 223 71806
7 2 722 227 163894
7 4 744 447 332568
8 5 855 558 477090
7 6 766 667 510922
All the couples:  [[3, 2], [7, 2], [7, 4], [8, 5], [7, 6]]

Bonus: just the couples lacking the corresponding digits in the partial products as well:
[3, 2]
[7, 2]

the code:
print('b c bcc ccb  b*c')
solutions = []
for c in range(0,10):
    for b in range(c+1,10):
        prod =(100*b + 11*c) * (110*c + b)
        s = str(prod)
        if str(b) in s:
            continue
        if str(c) in s:
            continue
        print(b,c,(100*b + 11*c),(110*c + b), (100*b + 11*c) * (110*c + b))
        solutions.append([b,c])
print('All the couples: ', solutions, '\n')
print('Bonus: just the couples lacking the corresponding digits in the partial products as well: ')

for aList in solutions:
    b = aList[0]
    c = aList[1]
    x = (100*b + 11*c)
    y = (110*c + b)
    partialProducts = str(x*b)+str(x*c)+str(y*b)+str(y*c)
    if str(b) in partialProducts:
        continue
    if str(c) in partialProducts:
        continue
    print(aList)

  Posted by Larry on 2020-11-28 08:39:07
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 (10)
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