Submit solution

Points:
7 (partial)

Time limit:
1.0s

Memory limit:
64M

Author:

Problem type

Allowed languages

Ada, Assembly, Awk, Brain****, C, C#, C++, COBOL, ~~CommonLisp~~, D, Dart, F#, Forth, Fortran, Go, ~~Groovy~~, Haskell, Intercal, Java, JS, Kotlin, Lisp, Lua, ~~Nim~~, ~~ObjC~~, OCaml, ~~Octave~~, Pascal, Perl, PHP, Pike, Prolog, Python, Racket, Ruby, Rust, Scala, Scheme, Sed, Swift, TCL, Text, Turing, VB, Zig

Winnie has fallen in love with the people from the kpop band group: BTS. In this group, there are people. Her love for each person can be modeled as a line of the form , with representing time, and representing her affection for the person.

You want to know, how many pairs of people will receive the same amount of affection from Winnie at a common point in time (including negative time)?

#### Input Specification

The first line will contain the integer , the number of people.

The next lines will each contain two integers, .

#### Output Specification

Output the number of pairs of people that will receive the same amount of affection from Winnie at a common point in time.

#### Subtasks

##### Subtask 1 [10%]

##### Subtask 2 [90%]

No further constraints.

#### Sample Input

```
4
1 3
2 3
0 2
1 2
```

#### Sample Output

`5`

## Comments