Under construction

Still being built. Things may change

Area

Time limit1sMemory limit1024 MB

Summary
Given n frames with heights and widths, the task is to print the largest area h times w among them.
Level

Easy1 of 10

Topics
Implementation
Solved
No attempts yet

Problem

Stuart has nn rectangular frames, numbered from 1 to nn. Frame ii has height hih_i and width wiw_i. The size of a frame is the area it covers. Find the area covered by the largest frame Stuart has.

Input

The first line contains a single integer nn. Each of the next nn lines contains two space-separated integers hih_i and wiw_i, the height and width of frame ii.

Output

Print one integer, the area covered by the largest frame.

Constraints

1≤n≤1001 \le n \le 100

1≤hi,wi≤10001 \le h_i, w_i \le 1000

Examples2

  1. Example 1

    Input
    3
    5 9
    19 4
    8 10
    
    Expected output
    80
    
  2. Example 2

    Input
    5
    8 2
    4 9
    3 8
    1 7
    9 4
    
    Expected output
    36