How many time did you login to your email account publicly and feared if someone might keylog you? Of course prevention is way better then the aftermath but Gmail has taken the next steps in protecting your account from simultaneous logins, preventing suspicious activities.
Now, if it looks like something unusual is going on with your account, Gmail will alert you by posting a warning message saying, “Warning: We believe your account was last accessed from…” along with the geographic region, as illustrated below:
In order to make this possible, Gmail keeps track of your frequently used IPs and then matches with a totally new one newly incurred. Apart fromt his, Gmail already featured list of IPs from which your account was last accessed. This info can be seen by clicking “show details” from the Footer of gmail page. It looks something like this:
Its always a good idea to change the password when you feel some unusual IP appears.