{"problem":{"name":"∙ (Bullet)","description":{"content":"We have caught $N$ sardines. The _deliciousness_ and _fragrantness_ of the $i$\\-th sardine is $A_i$ and $B_i$, respectively. We will choose one or more of these sardines and put them into a cooler. Ho","description_type":"Markdown"},"platform":"AtCoder","limit":{"time_limit":2000,"memory_limit":262144},"difficulty":"None","is_remote":true,"is_sync":true,"sync_url":null,"sign":"abc168_e"},"statements":[{"statement_type":"Markdown","content":"We have caught $N$ sardines. The _deliciousness_ and _fragrantness_ of the $i$\\-th sardine is $A_i$ and $B_i$, respectively.\nWe will choose one or more of these sardines and put them into a cooler. However, two sardines on bad terms cannot be chosen at the same time.\nThe $i$\\-th and $j$\\-th sardines $(i \\neq j)$ are on bad terms if and only if $A_i \\cdot A_j + B_i \\cdot B_j = 0$.\nIn how many ways can we choose the set of sardines to put into the cooler? Since the count can be enormous, print it modulo $1000000007$.\n\n## Constraints\n\n*   All values in input are integers.\n*   $1 \\leq N \\leq 2 \\times 10^5$\n*   $-10^{18} \\leq A_i, B_i \\leq 10^{18}$\n\n## Input\n\nInput is given from Standard Input in the following format:\n\n$N$\n$A_1$ $B_1$\n$:$\n$A_N$ $B_N$\n\n[samples]","is_translate":false,"language":"English"}],"meta":{"iden":"abc168_e","tags":[],"sample_group":[["3\n1 2\n-1 1\n2 -1","5\n\nThere are five ways to choose the set of sardines, as follows:\n\n*   The $1$\\-st\n*   The $1$\\-st and $2$\\-nd\n*   The $2$\\-nd\n*   The $2$\\-nd and $3$\\-rd\n*   The $3$\\-rd"],["10\n3 2\n3 2\n-1 1\n2 -1\n-3 -9\n-8 12\n7 7\n8 1\n8 2\n8 4","479"]],"created_at":"2026-03-03 11:01:14"}}