PauliT
PauliT

Reputation: 1

Boundary Folding Hash Function

What is the value of the Boundary Folding Hash Function if K = 43-57-69 and TSize = 100?

If it is Shift Folding I know how to solve: I sum 43, 57 and 69. After that, I mod with Tsize. (43 + 57 + 69) % 100 = 69.

But with Boundary I can't do that.

Upvotes: 0

Views: 331

Answers (1)

Fares Gamil
Fares Gamil

Reputation: 1

In boundary folding you basically take the first not folded and then fold the next one and so on and so forth, here in this example you will take 43 unfolded which is 43 and fold the next one (57) to be 75 and the next to be unfolded, at the end you will have 43,75 and 69, add them (43 + 75 + 69 = 187) to get 187 and then mod them to 100 to get the index within the size you where given in the question which is 100 and answer will be 87, I know the answer is late, but it's never too late for learning.

Upvotes: 0

Related Questions