The influenza virus that causes "the flu" is transmitted from person to person through the air, and from touching things contaminated with the virus. Of these two routes, probably the person to person air transmission is the most common. When someone with an active influenza infection sneezes, thousands of tiny liquid particles are ejected from their nose and mouth that contain the virus. The particles can be inhaled by someone nearby and they can become infected. This is why someone with the flu should always wear a mask when out in public. Sometimes after a big sneeze, the virus will attach itself to a door nob, or a railing, or other man made object. The virus can survive there for up to a few days. If someone touches this object, the virus can be transferred to the person's hand. If that person then touches their hand to their mouth, then they can become infected.
As you can see, the surface to mouth transmission takes more steps, and is therefore less common. However, everyone that rides in a subway will be susceptible to the viruses sneezed out by the other passengers. Therefore, it is always a good idea to cover your mouth when you sneeze and wash you hands a several times per day. Wearing gloves will only help if you don't touch the gloves to your mouth.
Please schedule an appointment with your primary care physician
to stay current on your flu shot
and other vaccines. This will reduce your likelihood of getting infected.