Como encontrar o valor máximo do conjunto de variáveis

Eu queria saber se alguém poderia me ajudar a encontrar o valor máximo de um conjunto de variáveis e atribuí-los a outra variável. Aqui está um trecho do meu código que pode ajudar a entender o que estou faland

// Ask for quarter values.
    System.out.println("What is the value of the first quarter?");
    firstQuarter = input.nextDouble();

    System.out.println("What is the value of the second quarter?");
    secondQuarter = input.nextDouble();

    System.out.println("What is the value of the third quarter?");
    thirdQuarter = input.nextDouble();

    System.out.println("What is the value of the fourth quarter?");
    fourthQuarter = input.nextDouble();

    //Tell client the maximum value/price of the stock during the year.     
    //maxStock = This is where I need help 
    System.out.println("The maximum price of a stock share in the year is: $" + maxStock + ".");

questionAnswers(16)

yourAnswerToTheQuestion