結果
| 問題 |
No.994 ばらばらコイン
|
| コンテスト | |
| ユーザー |
monnu
|
| 提出日時 | 2020-05-26 21:32:01 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 53 ms / 2,000 ms |
| コード長 | 327 bytes |
| コンパイル時間 | 1,335 ms |
| コンパイル使用メモリ | 166,372 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-10-13 03:01:30 |
| 合計ジャッジ時間 | 3,399 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 23 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
using ll=long long;
using Graph=vector<vector<pair<int,int>>>;
#define INF 1000000000000000000
#define MOD 1000000007
int main(){
int N,K;
cin>>N>>K;
for(int i=0;i<N-1;i++){
int a,b;
cin>>a>>b;
}
if(K>N){
cout<<-1<<endl;
}else{
cout<<K-1<<endl;
}
}
monnu