XCOM 2’s Sharpshooter is an evolution of the Sniper class from XCOM: Enemy Unknown. Unlike its predecessor, the Sharpshooter isn’t exclusively a long-range, high-damage unit, and offers players the freedom to specialize in pistols, as well.
The skills in both pistols and sniper rifles allow for some really interesting combinations with the Sharpshooter in XCOM 2. For example, using the Death From Above skill in the sniper tree allows a Sharpshooter to perform an extra action when they kill an enemy at lower elevation. Combine this with the pistol tree skill Fan Fire, which lets Sharpshooters fire three consecutive pistol shots at a single target, and your Sharpshooter can unleash a lot of damage in a single turn.
This is just one example of how skills from both trees can work together in unique ways.
Learn more about XCOM 2’s other classes: