-
1 Attachment(s)
Just wondering!
Hi!
I've got a puzzle for you.
If you can achieve this in under an hour, well, that'd be amazing!
If you are the only one, well, That'd be astounding!
If you are one of many, then he/she who does it the fastest wins!!!
Attached you will see a diagram of a 7 ring hex.
It contains 127 cells, arranged in a semi spiral pattern from the center outwards.
With 127 cells, if all the numbers 0 and 1 were as evenly entered in each and every cell, you would have either 64 cells with ones or 63 cells with ones.
I Propose the object is you must place 64 ones in those cells such that every row adds to an even number of ones.
The overall 7 ring hex has 39 rows, of which 13 are identified as the rows 0,3,6, 9,12,15,18,21,24,27,30,33,36
There are 26 other rows, in the two other 120 degree orientation.
Below you will see a text version of what each row's {G_n or Groupp} cell make up is.
Can you create a program such that it will iterate to its first valid arrangement in an hour or less?
BONUS POINTS1: Only 63 Cells with 1's, each row adds to an odd number!
BONUS POINTS2: Allow it to be expandable to N-Rings!
:)
-Lou
Rows {G_n} and the cells {C_nn} they contain:
G_00 : C_097 C_098 C_099 C_100 C_101 C_102 C_103
G_01 : C_091 C_121 C_122 C_123 C_124 C_125 C_126
G_02 : C_109 C_110 C_111 C_112 C_113 C_114 C_115
G_03 : C_066 C_067 C_068 C_069 C_070 C_071 C_096 C_104
G_04 : C_061 C_086 C_087 C_088 C_089 C_090 C_092 C_120
G_05 : C_076 C_077 C_078 C_079 C_080 C_081 C_108 C_116
G_06 : C_041 C_042 C_043 C_044 C_045 C_065 C_072 C_095 C_105
G_07 : C_037 C_057 C_058 C_059 C_060 C_062 C_085 C_093 C_119
G_08 : C_049 C_050 C_051 C_052 C_053 C_075 C_082 C_107 C_117
G_09 : C_022 C_023 C_024 C_025 C_040 C_046 C_064 C_073 C_094 C_106
G_10 : C_019 C_034 C_035 C_036 C_038 C_056 C_063 C_084 C_094 C_118
G_11 : C_028 C_029 C_030 C_031 C_048 C_054 C_074 C_083 C_106 C_118
G_12 : C_009 C_010 C_011 C_021 C_026 C_039 C_047 C_063 C_074 C_093 C_107
G_13 : C_007 C_017 C_018 C_020 C_033 C_039 C_055 C_064 C_083 C_095 C_117
G_14 : C_013 C_014 C_015 C_027 C_032 C_047 C_055 C_073 C_084 C_105 C_119
G_15 : C_002 C_003 C_008 C_012 C_020 C_027 C_038 C_048 C_062 C_075 C_092 C_108
G_16 : C_001 C_006 C_008 C_016 C_021 C_032 C_040 C_054 C_065 C_082 C_096 C_116
G_17 : C_004 C_005 C_012 C_016 C_026 C_033 C_046 C_056 C_072 C_085 C_104 C_120
G_18 : C_000 C_001 C_004 C_007 C_013 C_019 C_028 C_037 C_049 C_061 C_076 C_091 C_109
G_19 : C_000 C_002 C_005 C_009 C_015 C_022 C_031 C_041 C_053 C_066 C_081 C_097 C_115
G_20 : C_000 C_003 C_006 C_011 C_017 C_025 C_034 C_045 C_057 C_071 C_086 C_103 C_121
G_21 : C_005 C_006 C_014 C_018 C_029 C_036 C_050 C_060 C_077 C_090 C_110 C_126
G_22 : C_003 C_004 C_010 C_014 C_023 C_030 C_042 C_052 C_067 C_080 C_098 C_114
G_23 : C_001 C_002 C_010 C_018 C_024 C_035 C_044 C_058 C_070 C_087 C_102 C_122
G_24 : C_015 C_016 C_017 C_030 C_035 C_051 C_059 C_078 C_089 C_111 C_125
G_25 : C_011 C_012 C_013 C_024 C_029 C_043 C_051 C_068 C_079 C_099 C_113
G_26 : C_007 C_008 C_009 C_023 C_036 C_043 C_059 C_069 C_088 C_101 C_123
G_27 : C_031 C_032 C_033 C_034 C_052 C_058 C_079 C_088 C_112 C_124
G_28 : C_025 C_026 C_027 C_028 C_044 C_050 C_069 C_078 C_100 C_112
G_29 : C_019 C_020 C_021 C_022 C_042 C_060 C_068 C_089 C_100 C_124
G_30 : C_053 C_054 C_055 C_056 C_057 C_080 C_087 C_113 C_123
G_31 : C_045 C_046 C_047 C_048 C_049 C_070 C_077 C_101 C_111
G_32 : C_037 C_038 C_039 C_040 C_041 C_067 C_090 C_099 C_125
G_33 : C_081 C_082 C_083 C_084 C_085 C_086 C_114 C_122
G_34 : C_071 C_072 C_073 C_074 C_075 C_076 C_102 C_110
G_35 : C_061 C_062 C_063 C_064 C_065 C_066 C_098 C_126
G_36 : C_115 C_116 C_117 C_118 C_119 C_120 C_121
G_37 : C_103 C_104 C_105 C_106 C_107 C_108 C_109
G_38 : C_091 C_092 C_093 C_094 C_095 C_096 C_097
Hmmm, first wayyy too big, now not so big, but terrible res!!!
:mad: