using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace ConsoleApplication1
{
    class Program
    {
        public static bool suparalelne(int ax, int ay, int bx, int by, int cx, int cy, int dx, int dy)
        {
            double a1 = by - ay;
            double b1 = ax - bx;
            double a2 = dy - cy;
            double b2 = cx - dx;
            if (a1 * b2 == a2 * b1) return true;
            else return false;
        }

        public static bool dvaputa(int ax, int ay, int bx, int by, int cx, int cy, int dx, int dy)
        {
            double d1 = (ax - bx) * (ax - bx) + (ay - by) * (ay - by);
            double d2 = (cx - dx) * (cx - dx) + (cy - dy) * (cy - dy);
            if (d1 == 4 * d2 || d2 == 4 * d1) return true;
            else return false;
        }

        static void Main(string[] args)
        {
            int n = int.Parse(Console.ReadLine());
            int br = 0;
            int[] x = new int[n];
            int[] y = new int[n];
            int i = 0;
            while (i < n)
            {
                string s = Console.ReadLine();
                string[] str = s.Split(' ');
                x[i] = int.Parse(str[0]);
                y[i] = int.Parse(str[1]);
                i++;
            }
            int a = 0;
            int b,c,d;

            while (a < n - 3)
            {
                b = a + 1;
                while (b < n - 2)
                {
                    c = b + 1;
                    while (c < n - 1)
                    {
                        d = c + 1;
                        while (d < n)
                        {
                            // while (d != a && d != b && d != c) d++;
                            if (suparalelne(x[a], y[a], x[b], y[b], x[c], y[c], x[d], y[d]) == true && dvaputa(x[a], y[a], x[b], y[b], x[c], y[c], x[d], y[d]) == true) br++;
                            if (suparalelne(x[a], y[a], x[c], y[c], x[b], y[b], x[d], y[d]) == true && dvaputa(x[a], y[a], x[c], y[c], x[b], y[b], x[d], y[d]) == true) br++;
                            if (suparalelne(x[a], y[a], x[d], y[d], x[b], y[b], x[c], y[c]) == true && dvaputa(x[a], y[a], x[d], y[d], x[b], y[b], x[c], y[c]) == true) br++;
                            d++;
                        }
                        c++;
                    }
                    b++;
                }
                a++;
            }
            Console.WriteLine(br);
          //  Console.ReadLine();
        }
    }
}