The NBA introduced the 3-point shot in the 1979-80 season as a way to reward players for making shots from long distance. Before that, all shots counted for two points regardless of how far away from the basket they were taken.
Since the long-distance shots are more difficult and are made less often, an extra point is given for making shots from beyond the designated 3-point line.
In the NBA, the 3-point line is 23-feet, 9-inches away from the basket, with the exception of the corners, where the line is 22 feet away from the basket.