### PROBLEM LINK:

**Author:** Hasan Jaddouh

**Tester:** Alexey Zayakin

**Editorialist:** Oleksandr Kulkov

### DIFFICULTY:

CAKEWALK

### PREREQUISITES:

Common sense

### PROBLEM:

You’re given four numbers a, b, c, d. You have to determine if you can make a rectangle of such lengthes.

### QUICK EXPLANATION

Do what the problem asks you to do.

### EXPLANATION:

In other words you have to check if two smallest and two largest numbers among this four are same. To do this you can sort all four numbers in whatever way you like and check that first two and last two numbers are both same. Example of solution:

```
int a[4];
cin >> a[0] >> a[1] >> a[2] >> a[3];
sort(a, a + 4);
cout << (a[0] == a[1] && a[2] == a[3] ? "YES" : "NO") << "
```

";

### AUTHOR’S AND TESTER’S SOLUTIONS:

Author’s solution can be found here.

Tester’s solution can be found here.