C++中b.cpp如何访问a.cpp中的vector变量?

a.cpp中有定义一个 vector 变量 students

a.cpp

struct student
{
    CString name;
    int age;
};

std::vector<student> students;

请问
b.cpp
中如何才能访问这个 students ?


结合楼下的答案,做了一份demo。
有需要的可以点击查看。

https://blog.csdn.net/wlzyan/article/details/105002636

在b.cpp中声明一个

extern std::vector<student> students;

a.h

struct Test
{
    int a;
    int b;
};

a.cpp

#include"a.h"
Test t{1,2};

b.cpp

#include<stdio.h>
#include"a.h"
extern Test t;
int main()
{
    printf("%d,%d\n",t.a,t.b);
    return 0;
}