To calculate cryptocurrency gains or losses, investors need to determine the cost basis of their cryptocurrency holdings and the sale price of the cryptocurrency at the time of the taxable event. The gains or losses can then be calculated by subtracting the cost basis from the sale price.