22852nd poster gets a cookie (cookie thread (Part 7)) (Part 10)

I think this might just be a brute-force-it thing?
Way I understand it, it’s basically “pick up to 8 of 16 dyes”, which is just under 40,000 possibilities.

Yeah, ok, never mind.
Back to the mines with me.

@Jane @Zone_Q11

How important is it to be able to speak Dutch in the Netherlands? Do you think someone can get by living in a city with just English?

4 Likes

Currently trying to get an international certification so I have a backup plan, even if it’s very logistically difficult and unlikely that i could even move to another country lol

4 Likes

One can dream

4 Likes

@tutuu was there for a year or so

5 Likes

i was about to suggest ireland/uk but i remembered the reason you may be considering moving

i don’t actually know how that is in non-northern ireland actually

2 Likes

Ireland is on the list yea
I love my UK buddies but terf island does not sound great :joy_cat:

3 Likes

let me know what you find out. when I looked into it briefly, it seemed hard to immigrate to any EU country without already having a job there or like being a close descendant of a citizen

3 Likes

actually i don’t know how that is in northern ireland
im just assuming stuff cause it follows uk laws

2 Likes

Yes ma’am !

2 Likes

I would visualize this by:

  • write a python script to brute force enumerate all the color combinations (might take too long to run but might work? probably worth trying at least)
  • Create an image in Python using an image library (for example cv2) that visualizes it however you want

the easiest way to do a brute force search I see is something roughly like
(haven’t tested this so it might have bugs but the general idea should work… unless its too slow)

import itertools

color_array = [] # put all the base colors in here
generated_colors = set()
num_colors_to_combine = 1
new_colors_found = True
colors_so_far = 0
while new_colors_found:
     for combination in itertools.combinations_with_replacement(color_array, num_colors_to_combine):
            generated_colors.add(compute_color(combination)) # define a compute_color method to compute the color after using the input combination
     new_colors_found = colors_so_far != len(generated_colors)
     colors_so_far = len(generated_colors)
     num_colors_to_combine += 1

if that ends up being too slow then uh
IDK what to do
if you don’t mind not enumerating every color you could cut off the loop at some number of iterations to get all the colors possible with N or less dyes
there might be a clever simplification but IDK

wait I think I misunderstood the formula

I thought the armor would depend only on the dyes used

but apparently it looks like if you use a few dyes in one craft, then use more dyes in another craft, you can get something different than if you use them all at once

uhhhhhhhh I think I would modify the code to have two loops
one for the number of crafts, and another for the dyes of each craft (which goes from 1 to 8 now)
a similar approach of “keep increasing the number of crafts until you don’t have any new colors” should still work though? (assuming, again, that its fast enough (which I kinda doubt but /shrug))

import itertools

def try_all_color_combinations(armor_color, generated_colors: set):
     for num in range(1, 9):
          for combination in itertools.combinations_with_replacement(color_array, num_colors_to_combine):
            generated_colors.add(compute_color(combination)) # define a compute_color method to compute the color after using the input combination

color_array = [] # put all the base colors in here
generated_colors = set()
num_crafts = 1
new_colors_found = True
colors_so_far = 0
while new_colors_found:
     for armor_color in generated_colors:
           try_all_color_combinations(armor_color, generated_colors)
     new_colors_found = colors_so_far != len(generated_colors)
     colors_so_far = len(generated_colors)
     num_crafts += 1

fixed code. probably

2 Likes

I would recommend serializing the computed colors so Python can load from a data file after the first run instead of re-computing the colors each run since they’re unlikely to change very frequently.

3 Likes

my exit plan is uruguay. i got my mom on board. see you in 20 years when the country uncollapses

4 Likes

my exit plan is using a video game speeding up time method for a couple decades

2 Likes