to know what digit does it ends, the pattern is
Power---ending----pattern
1--------------2------------2
2--------------4------------4
3--------------8------------8
4-------------16-----------6
5-------------32-----------2
6-------------64-----------4
7-----------128-----------8
8-----------256-----------6
9-----------512-----------2
10--------1024----------4
Now we have seen that there is a pattern of 2-4-8-6-2-4-8-6 repeating for every power of four so for 2^5028 it ends in:
5028 / 4 = 1257
the answer is 1257 with no remainder so the number 2^5028 will end 6