Quiz: Designing Functions
A short quiz to test your understanding of the function prototypes.
Let’s solve some quiz questions below to revise writing the function prototypes. In the quiz, we may have multiple correct options. So let’s start!
Function Prototypes
1
(Select all that apply.) Given three points (where each point has x, y coordinates), the module should tell whether the input points represent an Equilateral, a Right-Angle, an Isosceles Right Angle, an Isosceles, or a Scalene triangle. Which of these function prototypes is correct?
A)
int triangleType(int p1x, int p1y, int, int, int, int);
B)
int triangleType(int p1, int p2, int p3);
C)
int triangleType(int p1x, int p1y, int p2x, int p2y, int p3x, int p3y);
Question 1 of 80 attempted