You are not logged in.
HIG + CAB = EDF
CIH + EDF = GBA
please help me i can t solve it. A-I is 1-9
There are many solutions to the first one, one of them is 124 + 659 = 783
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
I think it needs to satisfy both.
Here lies the reader who will never open this book. He is forever dead.
Taking a new step, uttering a new word, is what people fear most. ― Fyodor Dostoyevsky, Crime and Punishment
The knowledge of some things as a function of age is a delta function.
Offline
This appears to be the only solution.
HIG + CAB = EDF
CIH + EDF = GBA
H = 4
I = 3
G = 8
C = 2
A = 1
B = 9
E = 6
D = 5
F = 7
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
Hi Bobby,
That's also the only solution I found.
"The good news about computers is that they do what you tell them to do. The bad news is that they do what you tell them to do." - Ted Nelson
Offline
Hi phrontister;
What method did you like?
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
M...the one I always use for alphametics. I couldn't work out how to get M to do the whole lot for me, though, so I got Excel to help me with the rest. I'm working on a complete solution in M right now, but it's rather messy because I don't know what I'm doing. Sort of getting there, I think, but have got some way to go yet.
"The good news about computers is that they do what you tell them to do. The bad news is that they do what you tell them to do." - Ted Nelson
Offline
Okay, remember you can translate what you did in Excel into M talk. It will be ugly but, "any port is good enough in a storm."
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
Hi Bobby,
Ok...a cuppa and a midnight snack later: done!
My output is {4,3,8,2,1,9,6,5,7}, from which values can easily be assigned to letters manually.
I tidied up my messy code, but no doubt went about the solution process the long way round.
"The good news about computers is that they do what you tell them to do. The bad news is that they do what you tell them to do." - Ted Nelson
Offline
That is good enough.
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
Yes, I'm happy. Whittled it down to 6 Lines of code.
"The good news about computers is that they do what you tell them to do. The bad news is that they do what you tell them to do." - Ted Nelson
Offline
Can I see your approach?
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
Ok, here 'tis. I got the formula for d from SE.
p = {1, 2, 3, 4, 5, 6, 7, 8, 9}; s1 = Permutations[p, {6}];
r = Select[
s1, (100 #[[1]] + 10 #[[2]] + #[[3]]) + (100 #[[4]] +
10 #[[5]] + #[[6]]) + (100 #[[4]] +
10 #[[2]] + #[[1]]) == (100 #[[3]] + 10 #[[6]] + #[[5]]) &];
For[n = 1, n < Length[r], n++, a = Part[r, n];
d = DeleteDuplicates[#2~Join~#]~Drop~Length[#2] &[p, a];
EDF = IntegerDigits[FromDigits[Take[a, 3]] + FromDigits[Take[a, -3]]];
If[d == Sort[EDF], Print[Flatten[Append[a, EDF]]]]]
"The good news about computers is that they do what you tell them to do. The bad news is that they do what you tell them to do." - Ted Nelson
Offline
That is interesting code, a bit different than mine.
SE where?
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
The fourth post...from Mr Wizard.
Last edited by phrontister (2014-12-10 10:56:26)
"The good news about computers is that they do what you tell them to do. The bad news is that they do what you tell them to do." - Ted Nelson
Offline
That is very good.
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
I would never have thought of it, of course. Even though I don't understand it, it was nice to be able to use it because it simplified some messy ideas I was toying with.
"The good news about computers is that they do what you tell them to do. The bad news is that they do what you tell them to do." - Ted Nelson
Offline
The great thing about coding is that you are allowed to use it even if you do not have any idea how it works.
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
I'll say!
That code fitted well into my plan, and worked because neither p nor a contained duplicates.
"The good news about computers is that they do what you tell them to do. The bad news is that they do what you tell them to do." - Ted Nelson
Offline
Is yours fast?
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
Instantaneous.
"The good news about computers is that they do what you tell them to do. The bad news is that they do what you tell them to do." - Ted Nelson
Offline
Then it beats mine which takes a couple of seconds.
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
Well, not exactly instantaneous...0.437500seconds, according to the Timing function.
"The good news about computers is that they do what you tell them to do. The bad news is that they do what you tell them to do." - Ted Nelson
Offline
What does it read with AbsoluteTiming?
In mathematics, you don't understand things. You just get used to them.
If it ain't broke, fix it until it is.
Always satisfy the Prime Directive of getting the right answer above all else.
Offline
0.435430
"The good news about computers is that they do what you tell them to do. The bad news is that they do what you tell them to do." - Ted Nelson
Offline