Im new to algorithms and am not haveing much luck on google, dont think im useing the right terms but here goes:
Im solveing a crackme, for fun. I've studied the code and determined the serial must add to 2F2 along with some other constraints. It is 6 chars long.
First I figured i could write a nested loop that counts from
1, 1, 1, 1, 1, 1 to 256, 256, 256, 256, 256, 256
That would take way too long, so I come up with an algorithm, it almost works except keeps returning to 256, were everything started. And thats where I need help.
It does not get much further then 255, 255, 127, 4, 1, 1
To descirbe my algorithm, I would first test for sum == target then,
if sum < target I would increase the current value by value = value + (max - value)/2
if sum > target I would reduce the curent value by value = value - (value - min)/2
max would equal 256, and min 0, but once sum < target, I set min equal to curent value since if the current value results in a sum less then what I want, reduceing it further makes no sence.
I think this is called divide and conquer but not sure. Where can I learn more about these type of algorithms?
