~x is equivalent to -(x + 1).
~~x = – (-(x + 1) + 1) = (x + 1) – 1 = x
~~x is equivalent to x
Extrapolating further ~~~~~~x would be same as x in the final result.
In the question, x value is given as 5 and “~” is repeated 6 times.
So, the correct answer for “~~~~~~5” is 5.