The gravitational force of attraction between two objects would be increased by "decreasing the distance between two objects"
Hope this helps!
Since the speed of sound is very high, we consider the time period of thunder and lightening negligible.
Now, d = vt
thus, d = 343 x 16.2
thus, d = 5556.6 metres
Thus, we are 5556.6 metres away from lightening ( approximately)