S
sam
Hi,
I'm just after an idea of how I could go about doing the following:
0 0 0 0 0 8 4 4
2 1 2 1 2 1 2 1
The top line of numbers is just a formatted number that will change but
always be 8 digits. The bottom row of numbers are weights. These will not
change but the corresponding digit above is multiplied by the digit immediate
below. i.e. 4*1=4 4*2=8, 8*1=8
the 4, 8, 8 are then added and used in a caulculation to create a check digit.
What I am having trouble with is how to loop through the top number to
multiply out each corresponding digit in the second row. Any ideas?
I'm just after an idea of how I could go about doing the following:
0 0 0 0 0 8 4 4
2 1 2 1 2 1 2 1
The top line of numbers is just a formatted number that will change but
always be 8 digits. The bottom row of numbers are weights. These will not
change but the corresponding digit above is multiplied by the digit immediate
below. i.e. 4*1=4 4*2=8, 8*1=8
the 4, 8, 8 are then added and used in a caulculation to create a check digit.
What I am having trouble with is how to loop through the top number to
multiply out each corresponding digit in the second row. Any ideas?