func_code_string: #include <bits/stdc++.h>   using namespace std;   const int N = 3e5 + 10;   int n, m, a[N], b[N], t[N];   int main() {     scanf( %d%d , &n, &m);     for (int i = 1; i <= m; i++) scanf( %d%d , &a[i], &b[i]);     int x = a[1], cnt = 0;     for (int i = 1; i <= m; i++)       if (a[i] == x || b[i] == x) cnt++;     for (int i = 1; i <= m; i++) {       if (a[i] == x || b[i] == x) continue;       if (a[i] == b[i])         t[a[i]]++;       else         t[a[i]]++, t[b[i]]++;     }     for (int i = 1; i <= n; i++)       if (t[i] + cnt == m) return puts( YES ), 0;     x = b[1], cnt = 0;     memset(t, 0, sizeof(t));     for (int i = 1; i <= m; i++)       if (a[i] == x || b[i] == x) cnt++;     for (int i = 1; i <= m; i++) {       if (a[i] == x || b[i] == x) continue;       if (a[i] == b[i])         t[a[i]]++;       else         t[a[i]]++, t[b[i]]++;     }     for (int i = 1; i <= n; i++)       if (t[i] + cnt == m) return puts( YES ), 0;     x = a[2], cnt = 0;     memset(t, 0, sizeof(t));     for (int i = 1; i <= m; i++)       if (a[i] == x || b[i] == x) cnt++;     for (int i = 1; i <= m; i++) {       if (a[i] == x || b[i] == x) continue;       if (a[i] == b[i])         t[a[i]]++;       else         t[a[i]]++, t[b[i]]++;     }     for (int i = 1; i <= n; i++)       if (t[i] + cnt == m) return puts( YES ), 0;     x = b[2], cnt = 0;     memset(t, 0, sizeof(t));     for (int i = 1; i <= m; i++)       if (a[i] == x || b[i] == x) cnt++;     for (int i = 1; i <= m; i++) {       if (a[i] == x || b[i] == x) continue;       if (a[i] == b[i])         t[a[i]]++;       else         t[a[i]]++, t[b[i]]++;     }     for (int i = 1; i <= n; i++)       if (t[i] + cnt == m) return puts( YES ), 0;     return puts( NO ), 0;   }   