您当前的位置: 首页 > 

钟钟终

暂无认证

  • 2浏览

    0关注

    232博文

    0收益

  • 0浏览

    0点赞

    0打赏

    0留言

私信
关注
热门博文

多源bfs Spicy Restaurant

钟钟终 发布时间:2022-05-01 14:22:13 ,浏览量:2

Spicy Restaurant 多源bfs+一个递推 做了好多题,这道题算做的比较少的题。

#include 

using namespace std;
int n,m,q,cnt,head[200005],w[100005],inf,dis[100005][105];
struct node
{
    int to,nxt;
}e[200005];

void add(int u,int v)
{
    e[++cnt].to=v;
    e[cnt].nxt=head[u];
    head[u]=cnt;
}
void bfs(int val)
{
    queueq;
    for(int i=1;i            
关注
打赏
1664378814
查看更多评论
0.0486s