Given a triangle and a square,  Their dimensions are as f…

  Given a triangle and a square,  Their dimensions are as follows: •    Triangle:  Values of all three sides are mentioned,  8, 6, 10 units•    Square:   Side: 4 units Questions:     1.    Calculate the perimeter of both the triangle and the square. Additional Requirement     •    The system output should display the perimeter with two decimal places.    •    The output should be formatted as follows: The perimeter of triangle is xx.yy The perimeter of square is xx.yy Note: This is an example output and does not reflect the actual values of the problem. The perimeter of a triangle is the sum of the lengths of its three sides. The perimeter of a square is the sum of the lengths of its four sides.