-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path441A
More file actions
61 lines (56 loc) · 1.11 KB
/
441A
File metadata and controls
61 lines (56 loc) · 1.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
#include<bits/stdc++.h>
#define lli long long int
#define vi vector<int>
#define vlli vector<lli>
#define pii pair<int,int>
#define vpi vector<pii>
#define mp unordered_map<char,int>
#define rep(i,a,b) for(int i=a;i<b;i++)
#define ff first
#define ss second
#define nline "\n"
#define MOD1 1000000007
#define MOD2 1000000009
using namespace std;
int main()
{
ios_base::sync_with_stdio(false);
cin.tie(NULL);
// int n;cin>>n;
// int l=0,r=0;
// bool flag=false;
// while(n!=0){
// int x,y;cin>>x>>y;
// if(n==1 && (x%2+y%2==1)){
// cout<<-1<<nline;
// return 0;
// }
// if(x%2+y%2==1){
// flag=true;
// }
// l+=x;r+=y;
// }
// if (l%2==0 && r%2==0) cout<<0<<nline;
// if ((l%2==1 && r%2==1) && flag) cout<<1<<nline;
// else cout<<-1<<nline;
lli n,v;
cin>>n>>v;
vi ans;
rep(i,0,n){
bool flag=false;
int num1,num2;
cin>>num1;
rep(j,0,num1){
cin>>num2;
if (!flag && v > num2){
flag=true;
ans.emplace_back(i);
}
}
}
cout<<ans.size()<<nline;
rep(i,0,ans.size()){
cout<<ans[i]+1<<" ";
}
return 0;
}