結果

問題 No.2403 "Eight" Bridges of Königsberg
コンテスト
ユーザー vjudge1
提出日時 2025-02-04 13:00:30
言語 C++17
(gcc 15.2.0 + boost 1.90.0)
コンパイル:
g++-15 -O2 -lm -std=c++17 -Wuninitialized -DONLINE_JUDGE -o a.out _filename_
実行:
./a.out
結果
RE  
実行時間 -
コード長 341 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 1,801 ms
コンパイル使用メモリ 210,092 KB
実行使用メモリ 6,400 KB
最終ジャッジ日時 2026-06-27 08:49:53
合計ジャッジ時間 9,081 ms
ジャッジサーバーID
(参考情報)
judge3_0 / judge2_1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample RE * 4
other RE * 31
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

#include <bits/stdc++.h>
using namespace std;
const int N=1e5+1;
int a[N];
int main()
{
	freopen("sakura.in","r",stdin);
	freopen("sakura.out","w",stdout);
	int n,m;
	cin>>n>>m;
	for(int i=1;i<=m;i++)
	{
		int x,y;
		cin>>x>>y;
		a[x]++;
		a[y]++;
	}
	int cnt=0;
	for(int i=1;i<=n;i++)
	{
		if(a[i]%2==1) cnt++;
	}
	cout<<cnt/2;
	return 0;
}
0