PROBLEM LINK:
Practice
Contest: Division 1
Contest: Division 2
Contest: Division 3
Contest: Division 4
Author: raysh07
Tester: sushil2006
Editorialist: iceknight1093
DIFFICULTY:
Cakewalk
PREREQUISITES:
None
PROBLEM:
You are given a rectangle with dimensions A\times B, and a square with side length C.
Check if they have the same area.
EXPLANATION:
The area of the rectangle is A\times B.
The area of the square is C\times C.
So, the answer is "Yes"
if A\times B = C\times C, and "No"
otherwise.
TIME COMPLEXITY:
\mathcal{O}(1) per testcase.
CODE:
Editorialist's code (PyPy3)
a, b, c = map(int, input().split())
print('Yes' if a*b == c*c else 'No')