# CF 240E, 一些意外状况.

Ruchiose posted @ Oct 31, 2014 04:02:13 PM in sigh with tags , 1893 阅读

1000 3983
1 2 1
2 3 1
3 4 1
4 5 1
......
997 998 1
998 999 1
999 1000 1
4 1 0
5 2 0
6 3 0
......
997 994 0
998 995 0
999 996 0
1000 997 0
7 1 0
8 2 0
9 3 0
10 4 0
......
998 992 0
999 993 0
1000 994 0
8 1 0
9 2 0
10 3 0
......
997 990 0
998 991 0
999 992 0
1000 993 0


// Author: Ruchiose
#include<iostream>
#include<cstdio>
#include<cstdlib>
#include<cstring>
#include<algorithm>
#include<cmath>
#define i64 long long
#define d64 long double
#define fortodo(i, f, t) for (i = f; i <= t; i++)
using namespace std;

int main()
{
int N = 1000;
printf("%d %d\n", N, N * 4 - 17);
int i;
fortodo(i, 1, N - 1) printf("%d %d 1\n", i, i + 1);
fortodo(i, 1, N - 3) printf("%d %d 0\n", i + 3, i);
fortodo(i, 1, N - 6) printf("%d %d 0\n", i + 6, i);
fortodo(i, 1, N - 7) printf("%d %d 0\n", i + 7, i);
}

-1

3
997 998 999

-1

999
629 2514 2515 2516 2517 2518 2519 2520 25......
-1
999
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17......
999
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17......

（似乎-1会被代码高亮君吃掉囧）

（杜教：你可以去学习一下O(MlogN)的写法）

UPD:

mega888 official doa 说:
Aug 30, 2021 12:06:24 AM

In this case you will begin it is important, it again produces a web site a strong significant internet site:

Satta king 说:
Sep 25, 2021 05:15:32 AM

In this particular article, you will see a summary, satisfy browse this post.

Kerala 11th Question 说:
Aug 16, 2022 10:10:34 PM

The Keralan government offers top-notch instruction, top-notch facilities, and a clean learning atmosphere. As a result of the state board's extensive provision of educational facilities, there has been a yearly increase in education at all levels in the state. On the official website, the Kerala +1 Important Question Paper 2023 was posted. Kerala 11th Question Paper 2023 The Kerala +1 Important Question Paper 2023 will be released as soon as it is ready, and the Kerala 11th Model Question Paper of the exams was posted fairly quickly on the official website. By utilising their registration number and Subjects-wise, they may check their Kerala +1 Important Question Paper 2023.

(输入验证码)
or Ctrl+Enter