Submission #44481
ソースコード
ステータス
コンパイルメッセージ
./Main.java:1: error: illegal character: '#'
#include<iostream>
^
./Main.java:1: error: class, interface, or enum expected
#include<iostream>
^
./Main.java:2: error: illegal character: '#'
#include<vector>
^
./Main.java:3: error: illegal character: '#'
#include<queue>
^
./Main.java:5: error: class, interface, or enum expected
typedef pair<int,int> pii;
^
./Main.java:7: error: class, interface, or enum expected
vector<pii>edge[100010];
^
./Main.java:9: error: class, interface, or enum expected
int costs[100010];
^
./Main.java:13: error: class, interface, or enum expected
int main(){
^
./Main.java:15: error: class, interface, or enum expected
cin>>n>>m;
^
./Main.java:16: error: class, interface, or enum expected
for(int i=1;i<=n;i++)costs[i]=1<<30;
^
./Main.java:16: error: class, interface, or enum expected
for(int i=1;i<=n;i++)costs[i]=1<<30;
^
./Main.java:16: error: class, interface, or enum expected
for(int i=1;i<=n;i++)costs[i]=1<<30;
^
./Main.java:18: error: class, interface, or enum expected
for(int i=0;i<m;i++){
^
./Main.java:18: error: class, interface, or enum expected
for(int i=0;i<m;i++){
^
./Main.java:18: error: class, interface, or enum expected
for(int i=0;i<m;i++){
^
./Main.java:21: error: class, interface, or enum expected
cin>>a>>b>>c; //辺の情報
^
./Main.java:22: error: class, interface, or enum expected
edge[a].push_back(make_pair(b,c)); //{a}→{b}
^
./Main.java:23: error: class, interface, or enum expected
edge[b].push_back(make_pair(a,c)); //{b}←{a}
^
./Main.java:24: error: class, interface, or enum expected
}
^
./Main.java:29: error: class, interface, or enum expected
pque.push(make_pair(0,1)); //最初にいる所なのでコストは0
^
./Main.java:30: error: class, interface, or enum expected
while(!pque.empty()){ //{pque}の中が空になるまで
^
./Main.java:32: error: class, interface, or enum expected
int cost=now.first;
^
./Main.java:33: error: class, interface, or enum expected
int pos=now.second; //今いる所
^
./Main.java:34: error: class, interface, or enum expected
pque.pop(); //取り出したものを{pque}から消す。
^
./Main.java:35: error: class, interface, or enum expected
for(int i=0;i<edge[pos].size();i++){
^
./Main.java:35: error: class, interface, or enum expected
for(int i=0;i<edge[pos].size();i++){
^
./Main.java:35: error: class, interface, or enum expected
for(int i=0;i<edge[pos].size();i++){
^
./Main.java:38: error: class, interface, or enum expected
int next_cost=edge[pos][i].second; //↑へのコスト
^
./Main.java:39: error: class, interface, or enum expected
if(cost+next_cost<costs[next]){
^
./Main.java:42: error: class, interface, or enum expected
pque.push(make_pair(costs[next],next));
^
./Main.java:43: error: class, interface, or enum expected
}
^
./Main.java:49: error: class, interface, or enum expected
else
^
./Main.java:51: error: class, interface, or enum expected
return 0;
^
./Main.java:52: error: class, interface, or enum expected
}
^
34 errors
セット
テストケース