编号 题目 状态 分数 总时间 内存 代码 / 答案文件 提交者 提交时间
#49342 #1253. 开课通知 Wrong Answer 10 1024 ms 23940 K C++ 11 / 1.3 K cgyz 2021-06-28 16:29:27
显示原始代码
#include <bits/stdc++.h>

using namespace std;

const int N = 1e6 + 10;
int n, m;

vector<int> clas[N];
void init(vector<int> &k, string n, int i) {
    int idx = 1;
    for (int j = 0; j < n.size(); j++) {
        if (n[j] == '1') {
            k.push_back(idx);
            clas[idx].push_back(i);
        }
        idx++;
    }
}

int main() {
    cin >> n >> m;
    vector<int> stu[N];
    for (int i = 0; i < n; i++) {
        string a;

        cin >> a;

        init(stu[i], a, i);
    }

    for (int i = 1; i <= n; i++) {
        bool flag = false;
        for (int j = 1; j <= m; j++) {
            if (clas[j].size() == 1) {
                //      cout<<j<<"!"<<endl;
                int tem = clas[j][0];
                flag = true;
                //  cout<<stu[tem].size();
                for (int l = 0; l < stu[tem].size(); l++) {
                    vector<int>::iterator it = find(clas[stu[tem][l]].begin(), clas[stu[tem][l]].end(), tem);

                    if (it != clas[stu[tem][l]].end()) {
                        clas[stu[tem][l]].erase(it);
                    }
                }
            }
        }
        if (flag == false)
            break;
    }
    int cnt = 0;
    for (int i = 1; i <= m; i++)
        if (clas[i].size() != 0)
            cnt++;

    cout << cnt;
}
子任务 #1
Wrong Answer
得分:10
测试点 #1
Wrong Answer
得分:0
用时:40 ms
内存:23872 KiB

输入文件(1.in

1000 1000
00000000000000000000000000000000000000000000000000000000000000000000000100000000000000000
<1001911 bytes omitted>

答案文件(1.out

553

用户输出

106

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #2
Wrong Answer
得分:0
用时:39 ms
内存:23860 KiB

输入文件(2.in

1000 1000
00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
<1001911 bytes omitted>

答案文件(2.out

390

用户输出

171

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #3
Wrong Answer
得分:0
用时:39 ms
内存:23860 KiB

输入文件(3.in

1000 1000
00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
<1001911 bytes omitted>

答案文件(3.out

570

用户输出

490

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #4
Wrong Answer
得分:0
用时:40 ms
内存:23800 KiB

输入文件(4.in

1000 1000
00000000000000000000000000000000000000000000000000000000000000000000000000000000010000000
<1001911 bytes omitted>

答案文件(4.out

898

用户输出

886

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #5
Wrong Answer
得分:0
用时:39 ms
内存:23924 KiB

输入文件(5.in

1000 1000
00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
<1001911 bytes omitted>

答案文件(5.out

959

用户输出

953

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #6
Wrong Answer
得分:0
用时:40 ms
内存:23824 KiB

输入文件(6.in

1000 1000
00000000000000000000000000000000000000000000000000000000000000000000000000000000010000000
<1001911 bytes omitted>

答案文件(6.out

985

用户输出

984

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #7
Accepted
得分:100
用时:39 ms
内存:23876 KiB

输入文件(7.in

1000 1000
00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
<1001911 bytes omitted>

答案文件(7.out

992

用户输出

992

系统信息

Exited with return code 0
测试点 #8
Wrong Answer
得分:0
用时:39 ms
内存:23924 KiB

输入文件(8.in

1000 1000
00000000000000000000000000000000000000000000000000000000000000000000000000000000000000001
<1001911 bytes omitted>

答案文件(8.out

995

用户输出

993

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #9
Accepted
得分:100
用时:40 ms
内存:23940 KiB

输入文件(9.in

1000 1000
00000000000000000000000000000000000000000100000000000000000000000000000000000000000000000
<1001911 bytes omitted>

答案文件(9.out

1000

用户输出

1000

系统信息

Exited with return code 0
测试点 #10
Accepted
得分:100
用时:39 ms
内存:23928 KiB

输入文件(10.in

1000 1000
00000000000000010000000000000000000000000000000000000000000000000000000000000000000000000
<1001911 bytes omitted>

答案文件(10.out

998

用户输出

998

系统信息

Exited with return code 0
测试点 #11
Wrong Answer
得分:0
用时:22 ms
内存:23796 KiB

输入文件(11.in

10000 10
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
000000
<119910 bytes omitted>

答案文件(11.out

9998

用户输出

5

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #12
Wrong Answer
得分:0
用时:23 ms
内存:23792 KiB

输入文件(12.in

10000 10
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
000000
<119910 bytes omitted>

答案文件(12.out

9997

用户输出

5

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #13
Wrong Answer
得分:0
用时:23 ms
内存:23812 KiB

输入文件(13.in

10000 10
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
000000
<119910 bytes omitted>

答案文件(13.out

10000

用户输出

10

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #14
Wrong Answer
得分:0
用时:23 ms
内存:23796 KiB

输入文件(14.in

10000 10
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
000000
<119910 bytes omitted>

答案文件(14.out

9999

用户输出

9

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #15
Wrong Answer
得分:0
用时:23 ms
内存:23764 KiB

输入文件(15.in

10000 10
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
000000
<119910 bytes omitted>

答案文件(15.out

10000

用户输出

10

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #16
Wrong Answer
得分:0
用时:23 ms
内存:23784 KiB

输入文件(16.in

10000 10
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
000000
<119910 bytes omitted>

答案文件(16.out

10000

用户输出

10

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #17
Wrong Answer
得分:0
用时:23 ms
内存:23756 KiB

输入文件(17.in

10000 10
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
000000
<119910 bytes omitted>

答案文件(17.out

10000

用户输出

10

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #18
Wrong Answer
得分:0
用时:23 ms
内存:23752 KiB

输入文件(18.in

10000 10
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
000000
<119910 bytes omitted>

答案文件(18.out

10000

用户输出

10

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #19
Wrong Answer
得分:0
用时:24 ms
内存:23796 KiB

输入文件(19.in

10000 10
0000000000
0000000000
1000000000
0000000000
0000000000
0000000000
0000000000
000000
<119910 bytes omitted>

答案文件(19.out

10000

用户输出

10

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #20
Wrong Answer
得分:0
用时:23 ms
内存:23796 KiB

输入文件(20.in

10000 10
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
0000000000
000000
<119910 bytes omitted>

答案文件(20.out

10000

用户输出

10

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #21
Wrong Answer
得分:0
用时:41 ms
内存:23824 KiB

输入文件(21.in

5000 200
000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
<1009910 bytes omitted>

答案文件(21.out

4930

用户输出

8

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #22
Wrong Answer
得分:0
用时:41 ms
内存:23836 KiB

输入文件(22.in

5000 200
000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
<1009910 bytes omitted>

答案文件(22.out

4922

用户输出

54

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #23
Wrong Answer
得分:0
用时:39 ms
内存:23752 KiB

输入文件(23.in

5000 200
000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
<1009910 bytes omitted>

答案文件(23.out

4940

用户输出

97

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #24
Wrong Answer
得分:0
用时:39 ms
内存:23820 KiB

输入文件(24.in

5000 200
000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000
<1009910 bytes omitted>

答案文件(24.out

4944

用户输出

111

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #25
Wrong Answer
得分:0
用时:39 ms
内存:23764 KiB

输入文件(25.in

5000 200
000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
<1009910 bytes omitted>

答案文件(25.out

4960

用户输出

145

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #26
Wrong Answer
得分:0
用时:40 ms
内存:23780 KiB

输入文件(26.in

5000 200
000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
<1009910 bytes omitted>

答案文件(26.out

4967

用户输出

157

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #27
Wrong Answer
得分:0
用时:39 ms
内存:23796 KiB

输入文件(27.in

5000 200
000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
<1009910 bytes omitted>

答案文件(27.out

4980

用户输出

176

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #28
Wrong Answer
得分:0
用时:40 ms
内存:23796 KiB

输入文件(28.in

5000 200
000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
<1009910 bytes omitted>

答案文件(28.out

4980

用户输出

177

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #29
Wrong Answer
得分:0
用时:41 ms
内存:23796 KiB

输入文件(29.in

5000 200
000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
<1009910 bytes omitted>

答案文件(29.out

4987

用户输出

185

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0
测试点 #30
Wrong Answer
得分:0
用时:41 ms
内存:23860 KiB

输入文件(30.in

5000 200
000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
<1009910 bytes omitted>

答案文件(30.out

4992

用户输出

192

Special Judge 信息

Files user_out and answer differ

系统信息

Exited with return code 0