import math


def calculateDeterminant(termA, termB, termC):
    """
    Calculates the determinant and returns the correct value or -1 if is a negative number.
    """
    firstCalc = math.pow(termB, 2) - (4*termA*termC)
    if(firstCalc < 0):
        return -1
    else:
        determinant = math.sqrt(firstCalc)
        return determinant