Anuj,
It should be pretty intuitive on which formula to use on the exam, but here's a few ways to distinguish. If given a chart, the Triangular Distribution will plot as a triangle while the Beta Distribution will plot more as a bell curve. You'll see Triangular Distribution used more holistically to capture the statistics of an entire project without a ton of historical data to fall back on, while Beta Distribution is better when there is already historical data to compare with. Thus, Triangular is less accurate and more of a "guesstimate".
Basically, if the exam asks you about new projects without a lot of available data or project experience, you are probably looking at using the Triangular Distribution.
- Steven