double toMaxHeight(double oldMaxHeight, newMaxHeight) { if (oldMaxHeight > newMaxHeight) { return oldMaxHeight; } else { return newMaxHeight; } }