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

Home > Logic
Shade-doku (Posted on 2007-08-02) Difficulty: 3 of 5
Every cell in the 6x6 grid is divided into four segments, each of which contains one digit. Only one of these digits is correct; the other three are red herrings! In the three starter cells (GA, LC and LE), the rogue numbers have been shaded.

Can you shade the rogue numbers in all the other cells, so that the finished grid has the numbers 1 to 6, once only, in every row, column and coloured rectangle?

A

B

C

D

E

F

G

1

5

3

2

5

3

4

1

3

6

1

4

2

3

1

4

1

2

6

5

4

1

5

2

H

4

5

2

3

4

3

5

1

2

3

6

5

2

6

1

5

2

1

3

4

1

5

4

3

I

6

1

2

3

1

5

2

6

5

4

3

6

3

2

5

1

6

2

4

5

3

2

5

2

J

6

1

4

5

1

3

5

6

2

3

1

3

2

3

1

6

4

5

3

1

5

6

5

2

K

5

4

3

1

5

4

2

3

1

2

3

4

6

1

4

5

2

6

5

4

3

4

5

6

L

1

2

5

4

3

4

6

2

6

1

2

1

3

6

1

2

5

2

1

5

2

3

6

4

See The Solution Submitted by Josie Faulkner    
Rating: 4.6000 (10 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution disregarding the starter squares | Comment 3 of 13 |

... there are 27 solutions.  The one that fits the starter squares is highlighted:

 

123645 123645 125634 125634 132645 132645
432516 432516 452316 452316 423516 423516
651423 651432 631425 631452 651423 651432
264351 264153 364152 364125 264351 264153
516234 516324 516243 516243 516234 516324
345162 345261 243561 243561 345162 345261
 
135642 145632 235641 235641 325641 325641
452316 523416 412356 451326 412356 451326
621453 631245 651432 612435 651423 612435
364125 264351 364125 364152 264135 264153
516234 416523 546213 546213 536214 536214
243561 352164 123564 123564 143562 143562
 
325641 512634 513642 513642 523614 523614
451326 423516 432516 432516 412536 431526
612453 631425 621435 621453 631425 612435
264135 264351 264153 264135 264351 264351
536214 156243 156324 156324 156243 156243
143562 345162 345261 345261 345162 345162
 
531642 531642 532614 532614 541632 542631
423516 423516 413526 421356 623415 213456
612435 612453 621435 615432 135246 631542
264153 264135 264351 364125 264351 164325
156324 156324 156243 156243 416523 456213
345261 345261 345162 243561 352164 325164
 
542631 543612 543612
613425 621435 621453
231546 135246 135246
164352 264351 264531
456213 416523 416325
325164 352164 352164

 
DECLARE SUB place (row!, col!)
DATA 1235,1234,1235,1456,1346,1245
DATA 2456,1235,1234,1345,1235,3456
DATA 1236,1235,1256,2456,2345,2356
DATA 1236,1456,1345,1356,2356,1235
DATA 1456,1345,2456,2345,1234,3456
DATA 1236,1245,2345,1256,1236,1246
CLEAR , , 9999
DIM SHARED b$(6, 6), poss$(6, 6), ct
CLS
FOR r = 1 TO 6: FOR c = 1 TO 6
  READ poss$(r, c)
NEXT: NEXT
place 1, 1
PRINT ct
SUB place (row, col)
 FOR i = 1 TO 4
   c$ = MID$(poss$(row, col), i, 1)
   b$(row, col) = c$
   good = 1
   FOR cc = 1 TO col - 1
     IF b$(row, cc) = c$ THEN good = 0: EXIT FOR
   NEXT
   IF good THEN
     FOR cr = 1 TO row - 1
      IF b$(cr, col) = c$ THEN good = 0: EXIT FOR
     NEXT
     IF good THEN
       IF row < 4 THEN rs = 1:  ELSE rs = 4
       SELECT CASE col
         CASE 1, 2
          cs = 1
         CASE 3, 4
          cs = 3
         CASE 5, 6
          cs = 5
       END SELECT
       FOR cr = rs TO row
         FOR cc = cs TO cs + 1
           IF cr < row OR cc < col THEN
             IF b$(cr, cc) = c$ THEN good = 0: EXIT FOR
           END IF
         NEXT
         IF good = 0 THEN EXIT FOR
       NEXT
       IF good THEN
          prow = (ct 6) * 7 + 1: pcol = (ct MOD 6) * 7 + 1
          IF row = 6 AND col = 6 THEN
             FOR r = 1 TO 6
              FOR c = 1 TO 6
                LOCATE prow + r, pcol + c
                PRINT b$(r, c);
              NEXT
              PRINT
             NEXT
             PRINT
             ct = ct + 1
          ELSE
            c = col + 1
            r = row
            IF c > 6 THEN c = 1: r = r + 1
            place r, c
          END IF
       END IF
     END IF
   END IF
 NEXT
END SUB

 

Edited on August 2, 2007, 11:29 am
  Posted by Charlie on 2007-08-02 11:15:49

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 (14)
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