个人记录强调关闭同步流后不能 scanf printf 但可以puts 不是全局变量记得初始化 三目运算符使用 cout 输出时 要加最外层括号 例: 检查输入时 g[i].u g[i].v g[i].w