求助第九个点

P1737 [NOI2016] 旷野大计算

可爱的小棉羊 @ 2024-01-16 15:15:23

#include<bits/stdc++.h>
using namespace std;
int main(){
    freopen("nodes9.out","w",stdout);
    int pos[20]={},row=16;
    for(int i=1;i<=16;i++)pos[i]=i;
    for(int i=1;i<=16;i++)printf("I\n");
    for(int i=1;i<=16;i++){
        for(int j=1;j+i<=16;j++){
            printf("+ %d %d\n",pos[j],pos[j+1]);//1  a+b
            printf("- %d\n",pos[j+1]);//2 -b
            printf("+ %d %d\n",pos[j],row+2);//3 a-b
            printf("C %d 0.00000000001\n",row+3);//4
            printf("< %d 41\n",row+4);//5
            printf("S %d\n",row+5);//6
            printf("< %d 179\n",row+6);//7 t
            printf("> %d 178\n",row+3);//8
            printf("+ %d %d\n",row+7,row+8);//9
            printf("S %d\n",row+9);//10
            printf("C %d -0.5\n",row+10);//11
            printf("< %d 190\n",row+11);//12
            printf("- %d\n",row+7);//13 -t
            printf("+ %d %d\n",row+12,row+13);//14 min(a-b,0)
            printf("- %d\n",row+14);//15
            printf("+ %d %d\n",pos[j],row+15);//16
            pos[j]=row+16;
            printf("- %d\n",row+16);//17
            printf("+ %d %d\n",row+1,row+17);//18
            pos[j+1]=row+18;
            row+=18; 
        }
    }
    for(int i=1;i<=16;i++)printf("O %d\n",pos[i]);
}

by 可爱的小棉羊 @ 2024-01-16 16:48:31

找了一下发现了一个问题:

printf("< %d 190\n",row+11);

应为

printf("< %d 180\n",row+11);

但还有


by 2023f2 @ 2024-06-18 14:52:53

还有什么


|