0
I want to enter two matrix indexes, and subtract that value.
For example I want to enter with index [0, 1]
and [2, 10]
. And then I want to subtract the value, to calculate the distance I’m between these points.
for (int i = 0; i < 1; i++)
{
for (int j = 0; j < 1; j++)
{
matriz = matriz1[i, j] - matriz2[i, j];
}
}
I did so, but it returns zero. Returns zero because it assumes the value for the indexes, not their position.
There’s a way I can do that?
I need to get the amount it represents to as many clues as I’m on [0, 1]
I’ll be at the [2, 10]
It would be interesting to put what you’ve already done and say where you’re struggling.
– Maniero
The doubt is in C# or C?
– Jéf Bueno
Search by "distance Manhattan"
– C. E. Gesser
I think that
i = 0; i < 1;i++
not going anywhere. I think.– Eric Wu