## Problem 424

A place to air possible concerns or difficulties in understanding ProjectEuler problems. This forum is not meant to publish solutions. This forum is NOT meant to discuss solution methods or giving hints how a problem can be solved.
Forum rules
As your posts will be visible to the general public you
are requested to be thoughtful in not posting anything
that might explicitly give away how to solve a particular problem.

This forum is NOT meant to discuss solution methods for a problem.

In particular don't post any code fragments or results.

Don't start begging others to give partial answers to problems

Don't ask for hints how to solve a problem

Don't start a new topic for a problem if there already exists one

Don't post any spoilers
LarryBlake
Posts: 100
Joined: Sat Aug 29, 2009 7:49 pm

### Problem 424

Two rules questions:

1. Can an answer (across or down) contain duplicate digits?
2. Can an answer (across or down) contain a zero?

AVN
Posts: 13
Joined: Mon Feb 11, 2013 10:00 pm

### Re: Problem 424

I haven't solved this problem (it's out of my league at the moment), but I have solved lots of Kakuro puzzles.
I can confirm that the answer on both questions is indeed no.

CFB
Posts: 3
Joined: Tue Sep 27, 2011 5:44 pm

### Re: Problem 424

I am devastated!!! So near to being in the first 100.
I get the correct solution for the first puzzle, and I get the correct sum for puzzles 1 to 10, but my sum for puzzles 1 to 200 is incorrect.
Can anyone give me a hint as to where my error might be? It is not an integer overflow problem.
Thanks
Colin

Marcus_Andrews
Posts: 1452
Joined: Wed Nov 09, 2011 5:23 pm

### Re: Problem 424

Ensure that each equation does not contain any repeated digits or zeroes. It's possible to sometimes get the right number (i.e. the A-J identifier) even if these constraints aren't met 100%, but this won't work for all cases.

Other than that, this is an input-file problem -- so it may be something "silly" like your code only parsing 199 instead of 200 puzzles because of a one-off line-reading error, etc.
CFB wrote:I am devastated!!! So near to being in the first 100.
I get the correct solution for the first puzzle, and I get the correct sum for puzzles 1 to 10, but my sum for puzzles 1 to 200 is incorrect.
Can anyone give me a hint as to where my error might be? It is not an integer overflow problem.
Thanks
Colin

kaifeng
Posts: 1
Joined: Sun Apr 28, 2013 9:27 am

### Re: Problem 424

I found more then one solution even for the sample puzzle; is that possible?
Here is one of my solutions. The difference in show in red.
424.png (6.74 KiB) Viewed 4403 times

TheEvil
Posts: 84
Joined: Sun Nov 13, 2011 10:38 am
Location: Szeged, Hungary

### Re: Problem 424

In the second row you have two 9's. Every row and coloumn must contain pairwise distinct digits, as far as I know.

whakamaru
Posts: 47
Joined: Thu May 06, 2010 10:08 pm

### Re: Problem 424

I can do them in the newspaper, easily, but can I translate that logic into lines of code? Probably not.

tim-brown
Posts: 2
Joined: Wed Jan 09, 2013 3:09 pm

### Re: Problem 424

I am finding two (or more) distinct solutions to some puzzles. e.g. line 9 below.

I see no duplicated numbers, and as far as my arithmetic goes, all of the sums add up.
But the two solutions give different contributions to the "sum of the answers ..."

Am I missing a rule here?

(Line 8 has the same problem; but it has (hXX,vXX) combinations, so this is simpler.)

Code: Select all

7,X,(vBB),(vBD),X,X,X,X,(hBB),C,E,(vEE),(vEC),X,X,(hBC),O,O,O,O,X,X,X,(hEF),H,O,A,(vJ),X,X,X,(hBD),O,O,O,(vI),X,X,(hBE),F,O,O,O,X,X,X,X,(hG),O,O

Code: Select all

[8,1,9,0,2,4,5,7,3,6]
X        v(BB=11) v(BD=10) X        X        X      X
h(BB=11) 9        2        v(EE=22) v(EC=29) X      X
h(BC=19) 2        1        7        9        X      X
X        h(EF=24) 7        9        8        v(J=6) X
X        X        h(BD=10) 2        5        3      v(I=3)
X        X        h(BE=12) 4        7        1      0
X        X        X        X        h(G=5)   2      3
=8190245736

[8,1,9,0,2,4,5,7,6,3]
X        v(BB=11) v(BD=10) X        X        X      X
h(BB=11) 9        2        v(EE=22) v(EC=29) X      X
h(BC=19) 2        1        7        9        X      X
X        h(EF=24) 7        9        8        v(J=3) X
X        X        h(BD=10) 2        7        1      v(I=6)
X        X        h(BE=12) 4        5        2      1
X        X        X        X        h(G=5)   0      5
=8190245763


Marcus_Andrews
Posts: 1452
Joined: Wed Nov 09, 2011 5:23 pm

### Re: Problem 424

Zeroes are not allowed.

tim-brown
Posts: 2
Joined: Wed Jan 09, 2013 3:09 pm

### Re: Problem 424

Marcus Stuhr wrote:Zeroes are not allowed.
Thanks for that. I's not clear on the problem description (IMHO).

Anyhow, here's hoping that it gets me unique answers.

LarryBlake
Posts: 100
Joined: Sat Aug 29, 2009 7:49 pm

### Re: Problem 424

I get xxxxxxxx through 5. Is that correct? For some reason, my answer for 10 is wrong.

EDIT: Found my mistake. Correct answer for 5 is 35673704235.

ludopulles
Posts: 2
Joined: Sat Jan 05, 2019 3:08 pm

### Re: Problem 424

TheEvil wrote:
Sun Apr 28, 2013 11:03 am
In the second row you have two 9's. Every row and coloumn must contain pairwise distinct digits, as far as I know.
So can someone confirm that the second puzzle on https://www.conceptispuzzles.com/index. ... kuro/rules actually is not allowed since 1 is used twice in the third column but in different 'blocks'?

ludopulles
Posts: 2
Joined: Sat Jan 05, 2019 3:08 pm

### Re: Problem 424

My error was because I accepted zeroes. I have it right now.

You may have the same digits in a row or column, as long as the digits in each block are distinct.