function surfaceAreaOfPyramid(sideLength, height) {
const surfaceArea = (sideLength * sideLength) + 2 *
( sideLength * Math.sqrt(Math.pow(height, 2) +
Math.pow((sideLength / 2), 2)) );
return surfaceArea;
}
const sideLength = 6;
const height = 11;
console.log(surfaceAreaOfPyramid(sideLength, height));
/*
run:
172.82105101189654
*/