|Ok so here's how this decoder works.|
Each character can be represented by a maximum number of 20 different numbers depending on its position.
The dot between the numbers is the delimiter per each character represented.
aaaaaaaaaaaaaaaaaaaa = 126.96.36.199.188.8.131.52.184.108.40.206.220.127.116.11.18.104.22.168
a in position 1 is 25, a in position 2 is 62.
So lets take an example of a string such as:
the two a's are in position 5 and 6, this means the last 2 characters (aa) encoded will be:
The entire table which includes all the combinations of 20 digits representing each character depending on its position can be found here:
So encoding the string:
1 is in the first position, so using this:
We can see 73 is the 1st.
2 is in the second position so using this:
We can see 109 is in the 2nd position.
3 is in the third position so using this:
We can see 51 is in the 3rd position
4 is in the 4th position so using this:
we can see 155 is in the 4th position
a is in the 5th position so using this:
we can see 126 is in the 5th position.
the second a is in the 6th position so using this:
we can see 243 is in the 6th position, leading to:
Now what i want to be able to do is, enter a set of numbers with the dot delimiter which is a maximum total of 20 characters and a minimum of one and get the decoded string back.
So if i enter e.g:
i will get:
if i enter:
i will get:
How can this be done in batch?
I have a pretty rough idea, calculate the number of dots inside the inputted set of numbers and add one to it, that will show the number of characters.
then do the for /f in () do (
set a = %%a
set b = %%b
depending on how many chars it is.
Then do something like:
type table.txt | find firstchar
and then check each number set and see if position of number found matches completely, if it is, then the 1st char is found, move onto 2nd char until all characters are found.