submission_id stringlengths 10 10 | problem_id stringlengths 6 6 | language stringclasses 3
values | code stringlengths 1 522k | compiler_output stringlengths 43 10.2k |
|---|---|---|---|---|
s238157441 | p00072 | C++ | #include <queue>
#include <vector>
#include <iostream>
#include <algorithm>
#define WHITE 0
#define GRAY 1
#define BLACK 2
#define INF 1000000000000000000LL
using namespace std;
long long prim(int V, vector<pair<long long, long long>> X[]) {
queue<int> Q; int dist[100], color[100];
for (int i = 0; i < V; i++) { dist[... | a.cc: In function 'long long int prim(int, std::vector<std::pair<long long int, long long int> >*)':
a.cc:8:13: warning: overflow in conversion from 'long long int' to 'int' changes value from '1000000000000000000' to '-1486618624' [-Woverflow]
8 | #define INF 1000000000000000000LL
| ^~~~~~~~~~~~~... |
s774757664 | p00072 | C++ | #include <queue>
#include <vector>
#include <iostream>
#include <algorithm>
#define WHITE 0
#define GRAY 1
#define BLACK 2
#define INF 1000000000000000000LL
using namespace std;
long long prim(int V, vector<pair<long long, long long>> X[]) {
queue<pair<long long, long long> > Q; long long dist[100], color[100];
for (... | a.cc: In function 'long long int prim(int, std::vector<std::pair<long long int, long long int> >*)':
a.cc:15:50: error: 'class std::queue<std::pair<long long int, long long int> >' has no member named 'top'; did you mean 'pop'?
15 | pair<long long, long long>pa = Q.top(); Q.pop();
| ... |
s227415759 | p00072 | C++ | #include <iostream>
#include <array>
#include <algorithm>
#include <cstdlib>
using namespace std;
constexpr int MAX_N = 100;
constexpr int MAX_M = MAX_N * MAX_N;
int par[MAX_N];
int myrank[MAX_N];
int n, m;
struct edge {
int a, b, d;
bool operator<(const edge &r) {
return d < r.d;
}
};
array<edg... | a.cc: In function 'int main()':
a.cc:73:36: error: expected primary-expression before '?' token
73 | sort(e.begin(), e.begin() + m);?\
74 | for (int i = 0; i < m; ++i) {
a.cc:74:5: error: expected primary-expression before 'for'
74 | for (int i = 0; i < m; ++i) {
| ^~~
a.cc:74:1: error: e... |
s393109156 | p00072 | C++ | #include "bits/stdc++.h"
using namespace std;
#define int long long
#define DEBUG 0
#define rep(i,a,b) for(int i=(a);i<(b);i++)
#define rrep(i,a,b) for(int i=(b)-1;i>=(a);i--)
#define all(a) (a).begin(),(a).end()
#define dump(o) if(DEBUG){cerr<<#o<<" "<<o<<endl;}
#define dumpc(o) if(DEBUG){cerr<<#o; for(auto &e:(o))ce... | a.cc: In function 'std::pair<long long int, std::vector<Edge> > prim(const Graph&, long long int)':
a.cc:78:15: error: no matching function for call to 'std::priority_queue<Edge>::push(int, long long int&, int)'
78 | q.push(-1, r, 0);
| ~~~~~~^~~~~~~~~~
In file included from /usr/include/c++/14... |
s176260806 | p00072 | C++ | #include<iostream>
#include<string>
#include<cmath>
#include<queue>
#include<vector>
#include<functional>
using namespace std;
struct P {
int from, to, cost;
};
int parent[10000];
int root(int x) {
if (parent[x] == x) return x;
return parent[x] = root(parent[x]);
}
void unite(int x, int y) {
x = parent[x];
y = par... | a.cc: In function 'int main()':
a.cc:37:25: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'?
37 | scanf_s("%d,%d,%d", &a, &b, &c);
| ^~~~~~~
| scanf
|
s737035658 | p00072 | C++ | #include<iostream>
#include<string>
#include<cmath>
#include<queue>
#include<vector>
#include<functional>
using namespace std;
struct P {
int from, to, cost;
};
int parent[10000];
int root(int x) {
if (parent[x] == x) return x;
return parent[x] = root(parent[x]);
}
void unite(int x, int y) {
x = parent[x];
y = par... | a.cc: In function 'int main()':
a.cc:37:25: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'?
37 | scanf_s("%d,%d,%d", &a, &b, &c);
| ^~~~~~~
| scanf
|
s504975383 | p00072 | C++ | #include<iostream>
#include<string>
#include<cmath>
#include<queue>
#include<vector>
#include<functional>
using namespace std;
struct P {
int from, to, cost;
};
int parent[10000];
int root(int x) {
if (parent[x] == x) return x;
return parent[x] = root(parent[x]);
}
void unite(int x, int y) {
x = parent[x];
y = par... | a.cc: In function 'int main()':
a.cc:37:25: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'?
37 | scanf_s("%d,%d,%d", &a, &b, &c);
| ^~~~~~~
| scanf
|
s050738617 | p00072 | C++ | #include<cstdio>
#include<iostream>
#include<algorithm>
#include<string>
#include<queue>
#include<vector>
#include<functional>
#include<cmath>
#include<map>
#include<stack>
#include<set>
#include<numeric>
#include<limits>
#include<iterator>
#define all(x) (x).begin(),(x).end()
#define rall(x) (x).rbegin(),(x).rend()
... | a.cc: In function 'int main()':
a.cc:88:25: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'?
88 | scanf_s("%d,%d,%d", &a, &b, &d);
| ^~~~~~~
| scanf
|
s388457561 | p00072 | C++ | using namespace std;
#define rep(i, n) for ( int i = 0; i < n; i++)
#define MAX 100
#define INFTY (1<<21)
int G[MAX][MAX], n;
void prim(){
int D[MAX], V[MAX], P[MAX], sum = 0;
rep(i, n) { D[i] = INFTY; V[i] = 0; }
D[0] = 0;
while(1){
int u, minv = INFTY;
rep(i, n) if ( !V[i] && minv > D[i]) {
... | a.cc: In function 'void prim()':
a.cc:28:5: error: 'cout' was not declared in this scope
28 | cout << sum<< endl;
| ^~~~
a.cc:1:1: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
+++ |+#include <iostream>
1 | using namespace std;
a.cc:... |
s958930972 | p00072 | C++ | #include <iostream>
#include <vector>
#include <cstdlib>
using namespace std;
struct place{
int id;
int weight;
};
const int unseen = -INT_MAX;
int update(vector<place>& vi, int k, int w){
vector<place>::iterator iter = vi.begin();
while(iter != vi.end() && (*iter).id != k) iter++;
if(iter == vi.end()){
place... | a.cc:11:21: error: 'INT_MAX' was not declared in this scope
11 | const int unseen = -INT_MAX;
| ^~~~~~~
a.cc:4:1: note: 'INT_MAX' is defined in header '<climits>'; this is probably fixable by adding '#include <climits>'
3 | #include <cstdlib>
+++ |+#include <climits>
4 | using nam... |
s678801208 | p00072 | C++ | #include <cstdio>
#include <cstring>
#include <algorithm>
#include <string>
#include <cmath>
#include <stack>
#include <vector>
#include <map>
#include <set>
#include <queue>
#include <list>
#include <iostream>
#include <climits>
#include <cfloat>
using namespace std;
//int main()
//{
// int n, m;
// int pos[100][100... | In file included from /usr/include/c++/14/queue:66,
from a.cc:10:
/usr/include/c++/14/bits/stl_queue.h: In instantiation of 'class std::priority_queue<int, std::vector<std::pair<int, int> >, std::greater<std::pair<int, int> > >':
a.cc:65:52: required from here
65 | priority_queue<i... |
s199703969 | p00072 | C++ | #include <iostream>
using namespace std;
#define SAFE_DELETE( x ) { if ( x ){ delete x; x = NULL; } }
struct tCell{
tCell() : x( 0 ), prev( NULL ), next( NULL ){}
int x;
tCell *prev, *next;
};
class MyArray{
public:
MyArray() : mSize( 0 ), head( NULL ), tail( NULL ){
head = new tCell;
tail = new tCell;
he... | a.cc: In member function 'int Route::calc()':
a.cc:88:47: error: 'INT_MAX' was not declared in this scope
88 | int nextTo, nextDis = INT_MAX;
| ^~~~~~~
a.cc:2:1: note: 'INT_MAX' is defined in header '<climits>'; this is probably fixable by a... |
s236144505 | p00072 | C++ | #include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
typedef int Weight;
struct Edge {
int src, dest;
Weight weight;
Edge(int src, int dest, Weight weight): src(src), dest(dest), weight(weight) {;}
bool operator<(const Edge &rhs) const {
return weight < rhs.weight;
}
};
struc... | a.cc: In constructor 'UnionFind::UnionFind()':
a.cc:20:5: error: 'memset' was not declared in this scope
20 | memset(parent, -1, sizeof(parent));
| ^~~~~~
a.cc:4:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
3 | #include <algorithm>
++... |
s392500812 | p00072 | C++ | #include<iostream>
#include<vector>
#include<cstdio>
#include<map>
#include<vector>
using namespace std;
int main(){
int n;
while(cin >>n,n){
int m,ans = 0;
vector<pair<int,pair<int,int> > > P;
bool done[100]={false};
cin >>m;
for(int i=0,a,b,c; i<m; i++){
scanf("%d,%d,%d",&a,&b,&c);
... | a.cc: In function 'int main()':
a.cc:18:5: error: 'sort' was not declared in this scope; did you mean 'short'?
18 | sort(P.begin(),P.end());
| ^~~~
| short
|
s464117086 | p00072 | C++ | #include<iostream>
#include<cstdio>
#include<cstring>
#include<algorithm>
using namespace std;
int e[100][100];
int main()
{
int n;
while(cin>>n,n)
{
int m;
int ans=0;
cin>>m;
for(int i = 0; i < n; ++i)
{
for(int j = 0; j < n; ++j)
{
e[i][j]=-1;
}
}
while(m--)
{
int l,r,c;
scanf("... | a.cc: In function 'int main()':
a.cc:36:32: error: 'INT_MAX' was not declared in this scope
36 | int mn=INT_MAX,num;
| ^~~~~~~
a.cc:5:1: note: 'INT_MAX' is defined in header '<climits>'; this is probably fixable by adding '#include <climits>'
4 | #incl... |
s955813462 | p00072 | C++ | #include <iostream>
#include <cstdio>
#include <vector>
#include <utility>
using namespace std;
class data {
public:
int a, b;
int c;
data(int p1, int p2, int cost) {
a = p1;
b = p2;
c = cost;
}
bool operator<(const data & c_) const {
return c > c_.c;
}
};
int n, m;
vector<data> cost;
vecto... | a.cc:24:12: error: template argument 1 is invalid
24 | vector<data> cost;
| ^
a.cc:24:12: error: template argument 2 is invalid
a.cc:25:12: error: template argument 1 is invalid
25 | vector<data> modefied_cost;
| ^
a.cc:25:12: error: template argument 2 is invalid
a.cc: In functi... |
s368221364 | p00072 | C++ | #include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
const int MAX = 1000;
int par[MAX],rank[MAX],n,m;
void init(int n){
for(int i = 0 ; i < n ; i++){
par[i] = i;
rank[i] = 0;
}
}
int find(int x){
if(par[x] == x) return x;
return par[x] = find(par[x]);
}
void unite(int x... | a.cc: In function 'void init(int)':
a.cc:12:5: error: reference to 'rank' is ambiguous
12 | rank[i] = 0;
| ^~~~
In file included from /usr/include/c++/14/bits/move.h:37,
from /usr/include/c++/14/bits/exception_ptr.h:41,
from /usr/include/c++/14/exception:166,
... |
s312901533 | p00072 | C++ | #include<cstdio.txt>
#include<cctype>
#include<cstring>
#include<cstdlib>
#include<algorithm>
#include<stack>
#include<queue>
#include<deque>
#include<vector>
#include<list>
#include<bitset>
#include<set>
using namespace std;
#define MAX_N 100
#define INF 1 << 20
int n, m, a, b, c, d[MAX_N][MAX_N], i, j, min[3], cnt... | a.cc:1:9: fatal error: cstdio.txt: No such file or directory
1 | #include<cstdio.txt>
| ^~~~~~~~~~~~
compilation terminated.
|
s634288468 | p00072 | C++ | #include <algorithm>
#include <iostream>
#include <vector>
using namespace std;
#define REP(i,n) for(i=0;i<n;i++)
struct branch{
int n1, n2, w;
};
bool greater(branch i, branch j){
return (i.w > j.w);
}
int main(){
while (1){
int n,i;
char c;
cin >> n;
if (n == 0) break;
vector <int> T(n);
REP(i,n) T[i] ... | a.cc: In function 'int main()':
a.cc:26:41: error: reference to 'greater' is ambiguous
26 | sort(S.begin(), S.end(),greater);
| ^~~~~~~
In file included from /usr/include/c++/14/string:49,
from /usr/include/c++/14/bits/locale_classes.h:40... |
s392245772 | p00073 | Java | import java.util.Scanner;
public class aoj0218 {
public static void main(String args[]){
Scanner in = new Scanner(System.in);
while(true){
int x = in.nextInt();
int h = in.nextInt();
if(x + h == 0)break;
double S = x*x+2*x*Math.sqrt((x/2)*(x/2)+h*h);
System.out.println(S);
}
}
} | Main.java:3: error: class aoj0218 is public, should be declared in a file named aoj0218.java
public class aoj0218 {
^
1 error
|
s194464818 | p00073 | Java | import java.util.Scanner;
public class AOJ0073 {
public static void main(String[] args) {
Scanner stdIn = new Scanner(System.in);
double x, h;
double s, t1, t2;
while (true) {
x = stdIn.nextInt();
h = stdIn.nextInt();
if (x == 0 && h == 0) break;
t1 = h * h + x * x / 4;
t2 = Math.sqr... | Main.java:3: error: class AOJ0073 is public, should be declared in a file named AOJ0073.java
public class AOJ0073 {
^
1 error
|
s081716429 | p00073 | Java | import java.io.*;
public class Main0073{
public static void main(String[] args){
BufferedReader reader=new BufferedReader(new InputStreamReader(System.in));
try{
String s,t;
while((s=reader.readLine()) !=null &&(t=reader.readLine()) !=null){
double n=Integer.parseInt(s);
double m=Integer.parseInt(t)... | Main.java:3: error: class Main0073 is public, should be declared in a file named Main0073.java
public class Main0073{
^
1 error
|
s175613546 | p00073 | C | #include<stdio.h>
#include<math.h>
int main()
{
int n;
int x,h;
double sei;
double s,san,tai,hen;
do{
scanf("%d%d",&x,&h);
if(x==0 && h==0)break;
sei=x*x;
tai=(double)x/2;
hen=tai*tai+h*h;
hen=sqrt(hen);
san=(double)hen*x/2;
S=4*san+sei;
printf("%0.6f",s);
}while(n);
return 0;
} | main.c: In function 'main':
main.c:17:9: error: 'S' undeclared (first use in this function)
17 | S=4*san+sei;
| ^
main.c:17:9: note: each undeclared identifier is reported only once for each function it appears in
|
s774672996 | p00073 | C | #include<stdio.h>
#include <math.h>
int main(void) {
int x,h;
double ans;
while(1) {
scanf("%d%d",&x,&h);
if(x==0 &&h==0) {
return(0);
}
ans = sprt(x*x+h*h);
printf("%ls\n",ans*x*2+x*x);
}} | main.c: In function 'main':
main.c:12:7: error: implicit declaration of function 'sprt'; did you mean 'sqrt'? [-Wimplicit-function-declaration]
12 | ans = sprt(x*x+h*h);
| ^~~~
| sqrt
|
s490223261 | p00073 | C | #include <stdio.h>
#include <math.c>
main(){
double x,h,s,a;
while(1){
scanf("%lf%lf",&x,&h);
if(x==0&&h==0) break;
a=(x/2)*(x/2)+h*h;
a=sqrt(a);
s=x*x+a*x*2;
printf("%f\n",s);
}
return 0;
} | main.c:2:10: fatal error: math.c: No such file or directory
2 | #include <math.c>
| ^~~~~~~~
compilation terminated.
|
s656291850 | p00073 | C | #include<stdio.h>
#include<math.h>
int main(){
int x.h;
double k;
while(1){
scanf("%d",&x);
scanf("%d",&h);
if(x==0&&h==0)break;
k=sqrt(h*h+x*x/4);
printf("%lf\n",2*x*k+x*x);
return 0;
} | main.c: In function 'main':
main.c:4:6: error: expected '=', ',', ';', 'asm' or '__attribute__' before '.' token
4 | int x.h;
| ^
main.c:4:6: error: expected expression before '.' token
main.c:7:13: error: 'x' undeclared (first use in this function)
7 | scanf("%d",&x);
| ^
main.c:7:... |
s974363107 | p00073 | C | #include<stdio.h>
#include<math.h>
int main(){
int x,h;
double k;
while(1){
scanf("%d",&x);
scanf("%d",&h);
if(x==0&&h==0)break;
k=sqrt(h*h+x*x/4);
printf("%lf\n",2*x*k+x*x);
return 0;
} | main.c: In function 'main':
main.c:13:1: error: expected declaration or statement at end of input
13 | }
| ^
|
s631226844 | p00073 | C | #include <stdio.h>
#include <math.h>
int main(int argc,char* argv[]){
for(;;){
int x,h;
double S,len,side;
scanf("%d",&x);
scanf("%d",&h);
if(x == 0 && h == 0){
break;
}
S = x*x;
len = sqrt((double)(x*x)/4 + h*h);
side = len*x*2;
printf("%.6lf\n",S + side);
... | main.c: In function 'main':
main.c:24:3: error: expected declaration or statement at end of input
24 | return 0;
| ^~~~~~
|
s868238703 | p00073 | C | #inlude <stdio.h>
#include <math.h>
int main(void)
{
double x,h,a;
while(scanf("%lf %lf",%x,&h)){
if(x==0&&h==0) break;
printf("%.6f\n",(x*sqrt((4*h*h)+(x*x)))+(x*x));
}
return 0;
} | main.c:1:2: error: invalid preprocessing directive #inlude; did you mean #include?
1 | #inlude <stdio.h>
| ^~~~~~
| include
main.c: In function 'main':
main.c:10:15: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
10 | while(scanf("%lf %lf",%x,&h)){
|... |
s311804681 | p00073 | C | #include<stdio.h>
#include<math.h>
int main(void)
{
double x,h,a;/*テ、ツクツ?ィツセツコ*//*テゥツォツ佚」ツ??/
double S; /*ティツ。ツィテゥツ敖「テァツゥツ?/
while(1){
scanf("%lf",&x);
scanf("%lf",&h);
if(x == 0 && h == 0){
break;
}
S = x * x + 4 * x * sqrt(x * x / 4 + h * h) / 2;
printf("%f\n",S);
}
retu... | main.c: In function 'main':
main.c:6:59: warning: trigraph ??/ ignored, use -trigraphs to enable [-Wtrigraphs]
6 | double x,h,a;/*テ、ツクツ?ィツセツコ*//*テゥツォツ佚」ツ??/
main.c:6:41: error: unterminated comment
6 | double x,h,a;/*テ、ツクツ?ィツセツコ*//*テゥツォツ佚」ツ??/
| ^
main.c:6:3: er... |
s866913501 | p00073 | C++ | #include<stdio.h>
#include<math.h>
int main(void)
{
double x,h,S,y,l;
while(1){
scanf("%lf %lf",&x,&h);
if(x==0 && h==0){
break;
}
y=x*x;
l=sqrt(h*h+(x/2)*(x/2))*x*2;
S=y+l;
printf("%f\n",S);
}
return 0; | a.cc: In function 'int main()':
a.cc:16:18: error: expected '}' at end of input
16 | return 0;
| ^
a.cc:4:1: note: to match this '{'
4 | {
| ^
|
s525460058 | p00073 | C++ | #include<iostream>
#include<cmath>
using namespace std;
int main(){
int x, h;
while(cin >> x >> '\n' >> h){
if(x == 0 && h == 0) break;
double ans = x * x + 4 * (x * sqrt((x/2)*(x/2) + h*h) * 0.5);
cout << ans << endl;
}
} | a.cc: In function 'int main()':
a.cc:6:24: error: no match for 'operator>>' (operand types are 'std::basic_istream<char>::__istream_type' {aka 'std::basic_istream<char>'} and 'char')
6 | while(cin >> x >> '\n' >> h){
| ~~~~~~~~ ^~ ~~~~
| | |
| ... |
s861725735 | p00073 | C++ | #include<iostream>
#include<cmath>
using namespace std;
int main(){
int x, h;
while(cin >> x ;cin >> h){
if(x == 0 && h == 0) break;
double ans = x * x + 4 * (x * sqrt((x/2)*(x/2) + h*h) * 0.5);
cout << ans << endl;
}
} | a.cc: In function 'int main()':
a.cc:6:23: error: expected ')' before ';' token
6 | while(cin >> x ;cin >> h){
| ~ ^~
| )
a.cc:6:33: error: expected ';' before ')' token
6 | while(cin >> x ;cin >> h){
| ^... |
s410845428 | p00073 | C++ | #include<iostream>
#include<algorithm>
using namespace std;
int main()
{
long long int a = 0;
long long int b = 0;
while (cin >> a, cin >> b)
{
long long int c = 0;
c = a*a*(a*a + b*b);
long long int d = 0;
d = sqrt(c * 10000000000);
cout << a * a + d / 100000 << '.' << d % 100000 << endl;
}
return 0... | a.cc: In function 'int main()':
a.cc:13:21: error: 'sqrt' was not declared in this scope
13 | d = sqrt(c * 10000000000);
| ^~~~
|
s378088986 | p00073 | C++ | #include<iostream>
#include<algorithm>
using namespace std;
int main()
{
long long int a = 0;
long long int b = 0;
while (cin >> a, cin >> b)
{
long long int c = 0;
c = a*a*(a*a + 4*b*b) * 10000000000;
long long int d = 0;
d = sqrt(c);
cout << a * a + d / 100000 << '.' << d % 100000 << endl;
}
retur... | a.cc: In function 'int main()':
a.cc:13:21: error: 'sqrt' was not declared in this scope
13 | d = sqrt(c);
| ^~~~
|
s444177537 | p00073 | C++ | #include<iostream>
#include<algorithm>
using namespace std;
int main()
{
long long int a = 0;
long long int b = 0;
while (cin >> a, cin >> b)
{
long long int c = a*a*(a*a + 4 * b*b) * 10000000000;
long long int d = sqrt(c);
cout << a * a + d / 100000 << '.' << d % 100000 << endl;
}
return 0;
} | a.cc: In function 'int main()':
a.cc:11:35: error: 'sqrt' was not declared in this scope
11 | long long int d = sqrt(c);
| ^~~~
|
s157976616 | p00073 | C++ | #include<iostream>
#include<algorithm>
using namespace std;
int main()
{
long long int a = 0;
long long int b = 0;
while (1)
{
cin >> a;
cin >> b;
if (a == 0 && b == 0)
{
break;
}
long long int c = a*a*(a*a + 4 * b*b) * 10000000000;
long long int d = sqrt(c);
cout << a * a + d / 100000 << '.' << ... | a.cc: In function 'int main()':
a.cc:17:35: error: 'sqrt' was not declared in this scope
17 | long long int d = sqrt(c);
| ^~~~
|
s930555556 | p00073 | C++ | #include<iostream>
using nmespace std;
int main(){
int w,h;
float ans;
while(1){
cin>>w>>h;
if(w==0&&h==0){
break;
}
ans=(float)w*w*2.0+w*h*6.0;
cout<<ans<<endl;
} | a.cc:2:7: error: expected nested-name-specifier before 'nmespace'
2 | using nmespace std;
| ^~~~~~~~
a.cc: In function 'int main()':
a.cc:7:1: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
7 | cin>>w>>h;
| ^~~
| std::cin
In file included from a.cc:1:
/usr/include/... |
s020194088 | p00073 | C++ | #include<iostream>
using namespace std;
int main(){
int w,h;
float ans;
while(1){
cin>>w>>h;
if(w==0&&h==0){
break;
}
ans=(float)w*w*2.0+w*h*6.0;
cout<<ans<<endl;
} | a.cc: In function 'int main()':
a.cc:13:2: error: expected '}' at end of input
13 | }
| ^
a.cc:3:11: note: to match this '{'
3 | int main(){
| ^
|
s212205406 | p00073 | C++ | 6
4
7
9
0
0 | a.cc:1:1: error: expected unqualified-id before numeric constant
1 | 6
| ^
|
s421265638 | p00073 | C++ | import java.util.*;
public class Main {
Scanner sc = new Scanner(System.in);
double x, h;
void run() {
for(;;) {
x = sc.nextInt();
h = sc.nextInt();
if (x == 0 && h == 0) break;
System.out.println(x + "|" + h);
double l = Math.sqrt(x*x/4 + h*h);
double res = x*x + 2 * x * ... | a.cc:1:1: error: 'import' does not name a type
1 | import java.util.*;
| ^~~~~~
a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:3:1: error: expected unqualified-id before 'public'
3 | public class Main {
| ^~~~~~
|
s089096588 | p00073 | C++ | import java.util.*;
public class Main {
Scanner sc = new Scanner(System.in);
double x, h;
void run() {
for(;;) {
x = sc.nextInt();
h = sc.nextInt();
if (x == 0 && h == 0) break;
//System.out.println(x + "|" + h);
double l = Math.sqrt(x*x/4 + h*h);
double res = x*x + 2 * x ... | a.cc:1:1: error: 'import' does not name a type
1 | import java.util.*;
| ^~~~~~
a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:3:1: error: expected unqualified-id before 'public'
3 | public class Main {
| ^~~~~~
|
s976786135 | p00073 | C++ | int main()
{
double x, h;
while(cin >> x >> h && (x || h))
cout << setprecision(10) << x * x + x * sqrt(x * x / 4 + h * h) * 2 << endl;
} | a.cc: In function 'int main()':
a.cc:4:15: error: 'cin' was not declared in this scope
4 | while(cin >> x >> h && (x || h))
| ^~~
a.cc:5:17: error: 'cout' was not declared in this scope
5 | cout << setprecision(10) << x * x + x * sqrt(x * x / 4 + h * h) * 2 << endl;
... |
s599829420 | p00073 | C++ | #include <iostream>
#include <sstream>
#include <algorithm>
#include <cstdio>
#include <string>
#include <vector>
#include <stack>
//AOJ0073
#define rep(x,to) for(int x=0;x<to;x++)
#define rep2(x,from,to) for(int x=from;x<to;x++)
using namespace std;
int main(void){
int x,h;
char k;
while(cin >> x >> h){
if(x==0... | a.cc: In function 'int main()':
a.cc:21:30: error: 'sqrt' was not declared in this scope
21 | double trg = sqrt(x*x/4.00 + 1.00*h*h) * x * 0.5;
| ^~~~
|
s540272826 | p00073 | C++ | #inlude <stdio.h>
#include <math.h>
int main(void)
{
double x,h,a;
while(scanf("%lf %lf",%x,&h)){
if(x==0&&h==0) break;
printf("%.6f\n",(x*sqrt((4*h*h)+(x*x)))+(x*x));
}
return 0;
} | a.cc:1:2: error: invalid preprocessing directive #inlude; did you mean #include?
1 | #inlude <stdio.h>
| ^~~~~~
| include
a.cc: In function 'int main()':
a.cc:10:31: error: expected primary-expression before '%' token
10 | while(scanf("%lf %lf",%x,&h)){
| ... |
s848792956 | p00073 | C++ | #include<stdio.h>
#include<math.h>
int main(){
int x,h,y,num=0;
while(1){
scanf("%d %d",&x,&h);
y=sqrt(x*x+h*h);
num=x*x+2*x*y;
if((x==0)&&(h==0)){
break;
}
printf("%d",num);
}
| a.cc: In function 'int main()':
a.cc:21:10: error: expected '}' at end of input
21 | }
| ^
a.cc:4:11: note: to match this '{'
4 | int main(){
| ^
|
s206931682 | p00073 | C++ | #include <iostream>
#include <cmath>
#include <cstdio>
using namespace std;
int main(){
double S,nx,xh;
int x,h;
for(;;){
cin >> x >> h;
if(x == 0 && h == 0) break;
nx = (double)x;
nh = (double)h;
S = sqrt(4*nh*nh+nx*nx)+nx*nx;
printf("%.6f\n" ,S);
}
return 0;
} | a.cc: In function 'int main()':
a.cc:14:5: error: 'nh' was not declared in this scope; did you mean 'h'?
14 | nh = (double)h;
| ^~
| h
|
s748619929 | p00073 | C++ | #include <stdio.h>
#include<math.h>
#include <string.h>
#include <ctype.h>
int main(){
double x,h,c,a;
while(1){
scanf("%lf%lf",&x,&h);
if(x==0&&h==0)break;
c=4*h*h+x*x;
c=sqrt(c);
a=x*c+x*x;
printf("%f\n",a)
return 0;
} | a.cc: In function 'int main()':
a.cc:14:17: error: expected ';' before 'return'
14 | printf("%f\n",a)
| ^
| ;
......
19 | return 0;
| ~~~~~~
a.cc:20:2: error: expected '}' at end of input
20 | }
| ^
a.cc:6:11: note: to match this '{'
6 | i... |
s657532142 | p00073 | C++ | #include <stdio.h>
#include<math.h>
#include <string.h>
#include <ctype.h>
int main(){
double x,h,c,a;
while(1){
scanf("%lf%lf",&x,&h);
if(x==0&&h==0)break;
c=4*h*h+x*x;
c=sqrt(c);
a=x*c+x*x;
printf("%f\n",a);
return 0;
} | a.cc: In function 'int main()':
a.cc:20:2: error: expected '}' at end of input
20 | }
| ^
a.cc:6:11: note: to match this '{'
6 | int main(){
| ^
|
s372814417 | p00073 | C++ | #include <cmath>
#include <cstdio>
using namespace std;
// x: base length, h: height of pyramid
double get_surface_area_of_pyramid(int x, int h) {
double height_of_triangle = sqrt(x * x / 4.0 + h * h);
return 2 * x * height_of_triangle + x * x;
}
int main(void) {
int x, h; // 4角推
while (cin >> x >> h) {
if ... | a.cc: In function 'int main()':
a.cc:16:16: error: 'cin' was not declared in this scope
16 | while (cin >> x >> h) {
| ^~~
a.cc:3:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
2 | #include <cstdio>
+++ |+#include <io... |
s250781322 | p00073 | C++ | #include<iostream>
#include<iomanip>
int main()
{
double x, h;
while( std::cin >> x >> h, x || h )
{
double t = sqrt( x * x / 4.0 + h * h );
std::cout << std::fixed << std::setprecision( 6 ) << x * t * 2.0 + x * x << std::endl;
}
return 0;
} | a.cc: In function 'int main()':
a.cc:9:28: error: 'sqrt' was not declared in this scope
9 | double t = sqrt( x * x / 4.0 + h * h );
| ^~~~
|
s920866374 | p00073 | C++ | loop do
x, h = 2.times.map{gets.to_i}
break if x==0 && h==0
puts x*x+Math.sqrt(4*h*h+x*x)*x
end | a.cc:1:1: error: 'loop' does not name a type
1 | loop do
| ^~~~
a.cc:3:3: error: expected unqualified-id before 'break'
3 | break if x==0 && h==0
| ^~~~~
|
s856085543 | p00073 | C++ | while true
x, h = 2.times.map{gets.to_i}
break if x==0 && h==0
puts x*x+Math.sqrt(4*h*h+x*x)*x
end | a.cc:1:1: error: expected unqualified-id before 'while'
1 | while true
| ^~~~~
a.cc:3:3: error: expected unqualified-id before 'break'
3 | break if x==0 && h==0
| ^~~~~
|
s368154198 | p00073 | C++ | while true
x = gets.to_i
h = gets.to_i
break if x==0 && h==0
puts x*x+Math.sqrt(4*h*h+x*x)*x
end | a.cc:1:1: error: expected unqualified-id before 'while'
1 | while true
| ^~~~~
|
s132139885 | p00073 | C++ | #include <iomanip>
#include <iostream>
using namespace std;
int main(){
while(1){
double x,h,s;
cin>>x>>h;
if(x==0&&h==0)break;
s=x*x+2*x*pow((x*x/4+h*h),0.5);
cout<<fixed<<setprecision(6)<<s<<endl;
}
} | a.cc: In function 'int main()':
a.cc:10:27: error: 'pow' was not declared in this scope
10 | s=x*x+2*x*pow((x*x/4+h*h),0.5);
| ^~~
|
s491138025 | p00074 | C | h,m,s,t;main(){for(;scanf("%d%d%d",&h,&m,&s),~h;printf("%d:%d:%d\n%d:%d:%d\n",t/3600,t/60%60,t%60,t*3/3600,t*3/60%60,t*3%60))t=h*3600+m*60+s; | main.c:1:1: warning: data definition has no type or storage class
1 | h,m,s,t;main(){for(;scanf("%d%d%d",&h,&m,&s),~h;printf("%d:%d:%d\n%d:%d:%d\n",t/3600,t/60%60,t%60,t*3/3600,t*3/60%60,t*3%60))t=h*3600+m*60+s;
| ^
main.c:1:1: error: type defaults to 'int' in declaration of 'h' [-Wimplicit-int]
main.c:1:3: e... |
s432232370 | p00074 | C | h,m,s,t;main(){h=!for(;scanf("%d%d%d",&h,&m,&s),~h;printf("%02d:%02d:%02d\n%02d:%02d:%02d\n",t/3600,t/60%60,t%60,t*3/3600,t*3/60%60,t*3%60))t=7200-h*3600-m*60-s;} | main.c:1:1: warning: data definition has no type or storage class
1 | h,m,s,t;main(){h=!for(;scanf("%d%d%d",&h,&m,&s),~h;printf("%02d:%02d:%02d\n%02d:%02d:%02d\n",t/3600,t/60%60,t%60,t*3/3600,t*3/60%60,t*3%60))t=7200-h*3600-m*60-s;}
| ^
main.c:1:1: error: type defaults to 'int' in declaration of 'h' [-Wimplic... |
s872878372 | p00074 | C | include<stdio.h>
int main(void)
{
int t,m,s,n,i,T=0,M=0,S=0,n3,sum,N;
scanf("%d",&t);
scanf("%d",&m);
scanf("%d",&s);
sum = 3600*t + 60*m + s;
N = 7200 - sum;
for(i=0;i<2;i++){
if( N>=3600 ){
T = N / 3600;
N = N % 3600;
}
if( N>=60 && N<3600 ){
M = N / 60;
N = N % 60;
}
S = N;
if(T<10){
prin... | main.c:1:8: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
1 | include<stdio.h>
| ^
|
s671547655 | p00074 | C++ | #include<iostream>
using namespace std;
int s[3], t[3], u[3], time, vtime[2];
int main() {
while (true) {
cin >> s[0] >> s[1] >> s[2];
if (s[0] == -1) { break; }
time = s[0] * 3600 + s[1] * 60 + s[2];
vtime[0] = 7200 - time;
vtime[1] = 7200 - (time / 3);
t[0] = vtime[0] / 3600;
t[1] = (vtime[0] / 60) % 6... | a.cc:3:23: error: 'int time' redeclared as different kind of entity
3 | int s[3], t[3], u[3], time, vtime[2];
| ^~~~
In file included from /usr/include/pthread.h:23,
from /usr/include/x86_64-linux-gnu/c++/14/bits/gthr-default.h:35,
from /usr/include/x86_... |
s589966564 | p00074 | C++ | include<stdio.h>
int main(void)
{
int t,m,s,n,i,T=0,M=0,S=0,n3,sum,N;
scanf("%d",&t);
scanf("%d",&m);
scanf("%d",&s);
sum = 3600*t + 60*m + s;
N = 7200 - sum;
for(i=0;i<2;i++){
if( N>=3600 ){
T = N / 3600;
N = N % 3600;
}
if( N>=60 && N<3600 ){
M = N / 60;
N = N % 60;
}
S = N;
if(T<10){
prin... | a.cc:1:1: error: 'include' does not name a type
1 | include<stdio.h>
| ^~~~~~~
|
s913449596 | p00074 | C++ | #include<iostream>
using namespace std;
int main(){
int h,m,s,sum1,sum2;
cin>>h>>m>>s;
if(h==-1&&m==-1&&s==-1)break;
sum1 = 60*60*60*h+60*60*m+60*s;
sum2 = sum1/3;
sum1 = 60*60*60*2 - sum1;
sum2 = 60*60*60*2 - sum2;
h = sum1/216000;
m = (sum1%216000)/3600;
s = ((sum1%216000)%3600)/60;
cout<<h<<':'<<m<<':'<<s... | a.cc: In function 'int main()':
a.cc:6:32: error: break statement not within loop or switch
6 | if(h==-1&&m==-1&&s==-1)break;
| ^~~~~
|
s993258517 | p00074 | C++ | #include<iostream>
#include<iomanip>
int main(){
while(1){
int t,m,s;
double T=0,N;
std::cin>>h>>m>>s;
if(h==-1&&m==-1&&s==-1)break;
T+=h*60;
T+=m;
T+=(s/60);
NT=120-T;
h=NT/60;
m=NT-h*60;
s=(NT-h*60-m)*60;
std::cout<<s... | a.cc:17:56: error: empty character constant
17 | std::cout<<std::setw(2)<<std::setfill('0')<<h<<'':';
| ^~
a.cc:17:59: warning: missing terminating ' character
17 | std::cout<<std::setw(2)<<std::setfill('0')<<h<<'':';
| ... |
s576454223 | p00074 | C++ | #include<iostream>
#include<iomanip>
int main(){
while(1){
int t,m,s;
double T=0,N;
std::cin>>h>>m>>s;
if(h==-1&&m==-1&&s==-1)break;
T+=h*60;
T+=m;
T+=(s/60);
NT=120-T;
h=NT/60;
m=NT-h*60;
s=(NT-h*60-m)*60;
std::cout<<... | a.cc: In function 'int main()':
a.cc:8:19: error: 'h' was not declared in this scope
8 | std::cin>>h>>m>>s;
| ^
a.cc:13:9: error: 'NT' was not declared in this scope; did you mean 'N'?
13 | NT=120-T;
| ^~
| N
|
s432783286 | p00074 | C++ | #include<iostream>
#include<iomanip>
int main(){
while(1){
int h,m,s;
double T=0,N;
std::cin>>h>>m>>s;
if(h==-1&&m==-1&&s==-1)break;
T+=h*60;
T+=m;
T+=(s/60);
NT=120-T;
h=NT/60;
m=NT-h*60;
s=(NT-h*60-m)*60;
std::cout<<... | a.cc:17:56: error: empty character constant
17 | std::cout<<std::setw(2)<<std::setfill('0')<<h<<'':';
| ^~
a.cc:17:59: warning: missing terminating ' character
17 | std::cout<<std::setw(2)<<std::setfill('0')<<h<<'':';
| ... |
s218798871 | p00074 | C++ | #include<iostream>
#include<iomanip>
int main(){
while(1){
int h,m,s;
double T=0,NT;
std::cin>>h>>m>>s;
if(h==-1&&m==-1&&s==-1)break;
T+=h*60;
T+=m;
T+=(s/60);
NT=120-T;
h=NT/60;
m=NT-h*60;
s=(NT-h*60-m)*60;
std::cout<... | a.cc:17:56: error: empty character constant
17 | std::cout<<std::setw(2)<<std::setfill('0')<<h<<'':';
| ^~
a.cc:17:59: warning: missing terminating ' character
17 | std::cout<<std::setw(2)<<std::setfill('0')<<h<<'':';
| ... |
s812637439 | p00074 | C++ | #include<iostream>
#include<iomanip>
int main(){
while(1){
int h,m,s;
double T=0,NT;
std::cin>>h>>m>>s;
if(h==-1&&m==-1&&s==-1)break;
T+=h*60;
T+=m;
T+=(s/60);
NT=120-T;
h=NT/60;
m=NT-h*60;
s=(NT-h*60-m)*60;
std::cout<... | a.cc:17:56: error: empty character constant
17 | std::cout<<std::setw(2)<<std::setfill('0')<<h<<'':';
| ^~
a.cc:17:59: warning: missing terminating ' character
17 | std::cout<<std::setw(2)<<std::setfill('0')<<h<<'':';
| ... |
s757373919 | p00075 | Java | import java.util.Scanner;
public class Main {
public static void main(String[] args) {
try (Scanner scanner = new Scanner(System.in)) {
while (scanner.hasNext()) {
String[] s = scanner.nextLine().split(",");
Student student = new Student(s[0], Double.parseDouble(s[1]), Double.parseDouble(s... | Main.java:10: error: illegal start of expression
if (student.bmi.is??????()) {
^
Main.java:10: error: illegal start of expression
if (student.bmi.is??????()) {
^
Main.java:10: error: illegal start of expression
if (student.bmi.is??????()) {
... |
s724765613 | p00075 | Java | import java.util.Scanner;
public class Main {
public static void main(String[] args) {
try (Scanner scanner = new Scanner(System.in)) {
while (scanner.hasNext()) {
String[] s = scanner.nextLine().split(",");
Student student = new Student(s[0], Double.parseDouble(s[1]), Double.parseDouble(s... | Main.java:10: error: illegal start of expression
if (student.bmi.is??????()) {
^
Main.java:10: error: illegal start of expression
if (student.bmi.is??????()) {
^
Main.java:10: error: illegal start of expression
if (student.bmi.is??????()) {
... |
s157472085 | p00075 | Java | import java.util.Scanner;
public class Main {
public static void main(String[] args) {
try (Scanner scanner = new Scanner(System.in)) {
while (scanner.hasNext()) {
String[] s = scanner.nextLine().split(",");
Student student = new Student(s[0], Double.parseDouble(s[1]), Double.parseDouble(s... | Main.java:22: error: <identifier> expected
Student(String studentId, double ??????kg, double ??????m) {
^
Main.java:22: error: <identifier> expected
Student(String studentId, double ??????kg, double ??????m) {
^
Main.java:22: error... |
s136337067 | p00075 | Java | public class Main {
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
int stnum;
double weight, height, BMI;
String data, datap[];
while( scan.hasNext()) {
data = scan.next();
datap = data.split(",",3);
stnum = Integer.valueOf(datap[0]);
weight = Double.valueOf(data... | Main.java:4: error: cannot find symbol
Scanner scan = new Scanner(System.in);
^
symbol: class Scanner
location: class Main
Main.java:4: error: cannot find symbol
Scanner scan = new Scanner(System.in);
^
symbol: class Scanner
location: class Main
2 errors
|
s866691314 | p00075 | Java | import java.io.*;
class Main
{
public static void main(String args[])throws IOException
{
BufferedReader input=new BufferedReader(new InputStreamReader(System.in));
String str;
while((str=input.readLine())!=null)
{
String str_ary[]=str.split(",");
Double a[]=new Double[3];
for(int i=0;i<3;i++)
... | Main.java:16: error: incompatible types: Double cannot be converted to int
if(a[1]/Math.pow(a[2],2)>=25)System.out.println((int)a[0]);
^
1 error
|
s614459934 | p00075 | Java | import java.util.ArrayList;
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
ArrayList l = new ArrayList();
while(sc.hasNext()){
String[] s = sc.next().split(",");
double w = Double.parseDouble(s[1]);
double h = Double.parseDo... | Main.java:16: error: incompatible types: Object cannot be converted to Integer
else for(Integer i:l)System.out.println(i);
^
Note: Main.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
1 error
|
s108745194 | p00075 | Java | import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
ArrayList l = new ArrayList();
while(sc.hasNext()){
double w = Double.parseDouble(s[1]);
double h = Double.parseDouble(s[2]);
i... | Main.java:11: error: cannot find symbol
double w = Double.parseDouble(s[1]);
^
symbol: variable s
location: class Main
Main.java:12: error: cannot find symbol
double h = Double.parseDouble(s[2]);
^
symbol: variable s
location: class Mai... |
s996845822 | p00075 | C | #include <stdio.h>
#include <math.h>
int main(void){
int a;double b,c;
while(scanf("%d",&a) != EOF){
scanf("%lf %lf",&b,&c)
if(b/(c*c)>=25){
printf("%d\n",a);
}
}
return 0;
} | main.c: In function 'main':
main.c:7:39: error: expected ';' before 'if'
7 | scanf("%lf %lf",&b,&c)
| ^
| ;
8 | if(b/(c*c)>=25){
| ~~
|
s116174517 | p00075 | C | #include<stdio.h>
int main{
int n;
double w;
double h;
scanf("%d,%lf,%lf",&n,&w,&h);
double bmi;
bmi = w/(h*h);
if(bmi>=25){
printf("%d",n);
}
return 0;
} | main.c:3:9: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token
3 | int main{
| ^
|
s840713678 | p00075 | C | #include<stdio.h>
int main(){
int i;
int a[10000],n=0,g
double w,h;
while(scanf("%d,%lf,%lf",&g,&w,&h)!=-1){
if(w/h/h>=25){
a[n]=g;
n++;
}
}
for(i=0;i<n;i++)
printf("%d\n",a[i]);
return 0;
} | main.c: In function 'main':
main.c:5:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'double'
5 | double w,h;
| ^~~~~~
main.c:6:27: error: 'g' undeclared (first use in this function)
6 | while(scanf("%d,%lf,%lf",&g,&w,&h)!=-1){
| ^
main.c:6:27: note: each ... |
s675539070 | p00075 | C | main(){
int n;
double g,m;
while(scanf("%d,%lf,%lf",&n,&g,&m)!=EOF){
if(25<=g/m/m)printf("%d\n",n);
}
return 0;
} | main.c:1:1: error: return type defaults to 'int' [-Wimplicit-int]
1 | main(){
| ^~~~
main.c: In function 'main':
main.c:5:11: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
5 | while(scanf("%d,%lf,%lf",&n,&g,&m)!=EOF){
| ^~~~~
main.c:1:1: note: includ... |
s044559336 | p00075 | C | n,g,m;int main(){
while(scanf("%d,%lf,%lf",&n,&g,&m)!=EOF){
if(25<=g/m/m)printf("%d\n",n);
}
return 0;
} | main.c:1:1: warning: data definition has no type or storage class
1 | n,g,m;int main(){
| ^
main.c:1:1: error: type defaults to 'int' in declaration of 'n' [-Wimplicit-int]
main.c:1:3: error: type defaults to 'int' in declaration of 'g' [-Wimplicit-int]
1 | n,g,m;int main(){
| ^
main.c:1:5: error:... |
s189202523 | p00075 | C | n;int main(g,m){
while(scanf("%d,%lf,%lf",&n,&g,&m)!=EOF){
if(25<=g/m/m)printf("%d\n",n);
}
return 0;
} | main.c:1:1: warning: data definition has no type or storage class
1 | n;int main(g,m){
| ^
main.c:1:1: error: type defaults to 'int' in declaration of 'n' [-Wimplicit-int]
main.c: In function 'main':
main.c:1:7: error: type of 'g' defaults to 'int' [-Wimplicit-int]
1 | n;int main(g,m){
| ^~~~
... |
s033781936 | p00075 | C | int main(n){double g,m;while(scanf("%d,%lf,%lf",&n,&g,&m)!=EOF)if(25<=g/m/m)printf("%d\n",n);return 0;} | main.c: In function 'main':
main.c:1:5: error: type of 'n' defaults to 'int' [-Wimplicit-int]
1 | int main(n){double g,m;while(scanf("%d,%lf,%lf",&n,&g,&m)!=EOF)if(25<=g/m/m)printf("%d\n",n);return 0;}
| ^~~~
main.c:1:30: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
... |
s387287656 | p00075 | C | main(n){double g,m;while(scanf("%d,%lf,%lf",&n,&g,&m)!=EOF)if(25<=g/m/m)printf("%d\n",n);return 0;} | main.c:1:1: error: return type defaults to 'int' [-Wimplicit-int]
1 | main(n){double g,m;while(scanf("%d,%lf,%lf",&n,&g,&m)!=EOF)if(25<=g/m/m)printf("%d\n",n);return 0;}
| ^~~~
main.c: In function 'main':
main.c:1:1: error: type of 'n' defaults to 'int' [-Wimplicit-int]
main.c:1:26: error: implicit declaratio... |
s679173207 | p00075 | C | main(n){double g,m;while(scanf("%d,%lf,%lf",&n,&g,&m)!=EOF)if(25<=g/m/m)printf("%d\n",n);} | main.c:1:1: error: return type defaults to 'int' [-Wimplicit-int]
1 | main(n){double g,m;while(scanf("%d,%lf,%lf",&n,&g,&m)!=EOF)if(25<=g/m/m)printf("%d\n",n);}
| ^~~~
main.c: In function 'main':
main.c:1:1: error: type of 'n' defaults to 'int' [-Wimplicit-int]
main.c:1:26: error: implicit declaration of func... |
s466793940 | p00075 | C | #include<stdio.h>
int main(){
float a,b,c;
printf("????¢¨??????????????????????????\???????????????:");
while(1){
scanf("%f",&a);
if(a<85){
printf("????????????\n??????????????\?????????:");
}
else{
printf("?????????????????§?????????(^??^)9m??????????????¬??°\n");
break;
}
}
printf("???????????... | main.c: In function 'main':
main.c:11:58: warning: trigraph ??( ignored, use -trigraphs to enable [-Wtrigraphs]
11 | printf("?????????????????§?????????(^??^)9m??????????????¬??°\n");
main.c:15:42: warning: trigraph ??( ignored, use -trigraphs to enable [-Wtrigraphs]
15 | printf("?... |
s674097312 | p00075 | C | #include<stdio.h>
int main(){
int x[1000],a,b,c,k=0,i;
scanf("%d,%lf,%lf",&a,&b,&c);
if(b/c/c>=25)
x[k++]=a;
}
for(i=0;i<k;i++)
printf("%d\n",x[i]);
return 0;
} | main.c:8:1: error: expected identifier or '(' before 'for'
8 | for(i=0;i<k;i++)
| ^~~
main.c:8:10: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
8 | for(i=0;i<k;i++)
| ^
main.c:8:14: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
8 |... |
s874175133 | p00075 | C | main(n){for(float h,w;~scanf("%d,%f,%f",&n,&w,&h);w/h/h<25||printf("%d\n",n));} | main.c:1:1: error: return type defaults to 'int' [-Wimplicit-int]
1 | main(n){for(float h,w;~scanf("%d,%f,%f",&n,&w,&h);w/h/h<25||printf("%d\n",n));}
| ^~~~
main.c: In function 'main':
main.c:1:1: error: type of 'n' defaults to 'int' [-Wimplicit-int]
main.c:1:24: error: implicit declaration of function 'scanf... |
s163939116 | p00075 | C | main(a){float b,c;for(;~scanf("%d,%f,%f",&a,&b,&c);)b/(c*c)>=25&&printf("%d\n",a),d++;!d&&puts("ツ該ツ督鳴づ按つオ");exit(0);} | main.c:1:1: error: return type defaults to 'int' [-Wimplicit-int]
1 | main(a){float b,c;for(;~scanf("%d,%f,%f",&a,&b,&c);)b/(c*c)>=25&&printf("%d\n",a),d++;!d&&puts("ツ該ツ督鳴づ按つオ");exit(0);}
| ^~~~
main.c: In function 'main':
main.c:1:1: error: type of 'a' defaults to 'int' [-Wimplicit-int]
main.c:1:25: error: i... |
s500226335 | p00075 | C | main(a){float b,c;for(;~scanf("%d,%f,%f",&a,&b,&c);)b/(c*c)>=25&&printf("%d\n",a),d++;exit(0);} | main.c:1:1: error: return type defaults to 'int' [-Wimplicit-int]
1 | main(a){float b,c;for(;~scanf("%d,%f,%f",&a,&b,&c);)b/(c*c)>=25&&printf("%d\n",a),d++;exit(0);}
| ^~~~
main.c: In function 'main':
main.c:1:1: error: type of 'a' defaults to 'int' [-Wimplicit-int]
main.c:1:25: error: implicit declaration of... |
s776198793 | p00075 | C | include <stdio.h>
int main(int argc,char* argv[]){
int s_sum;
double w,len;
while(scanf("%d,%lf,%lf",&s_sum,&w,&len) != EOF){
if(w/(len*len) >= 25.0){
printf("%d\n",s_sum);
}
}
return 0;
} | main.c:1:9: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
1 | include <stdio.h>
| ^
|
s412421960 | p00075 | C | #include<stdio.h>
int main() {
int num;
double w , h;
while(1) {
scanf("%d",&num);
if(num==EOF)break;
scanf("%f",&w);
scanf("%f",&h);
if(w/(h*h)>=25.0)
printf("%d\n",count);
}
return 0;
} | main.c: In function 'main':
main.c:11:15: error: 'count' undeclared (first use in this function)
11 | printf("%d\n",count);
| ^~~~~
main.c:11:15: note: each undeclared identifier is reported only once for each function it appears in
|
s872632716 | p00075 | C | main(){int x,sum=0;double a,b;while(scanf("%d,%lf,%lf",&x,&a,&b)!=EOF){float y=a/b;y/=b;if(y>=25)printf("%d\n",x);}return 0;} | main.c:1:1: error: return type defaults to 'int' [-Wimplicit-int]
1 | main(){int x,sum=0;double a,b;while(scanf("%d,%lf,%lf",&x,&a,&b)!=EOF){float y=a/b;y/=b;if(y>=25)printf("%d\n",x);}return 0;}
| ^~~~
main.c: In function 'main':
main.c:1:37: error: implicit declaration of function 'scanf' [-Wimplicit-functi... |
s151088692 | p00075 | C++ | #include<stdio.h>
int main(){
double y,z;
int x;
while(scanf("%d,%lf,%lf",&x.&y,&z);
if((y/z/z)>=25)printf("%d\n",x);
}
return 0;
} | a.cc: In function 'int main()':
a.cc:7:29: error: expected unqualified-id before '&' token
7 | while(scanf("%d,%lf,%lf",&x.&y,&z);
| ^
a.cc:7:35: error: expected ')' before ';' token
7 | while(scanf("%d,%lf,%lf",&x.&y,&z);
| ~ ^
| ... |
s238931306 | p00075 | C++ | #include<stdio.h>
int main(){
double y,z;
int x;
while(scanf("%d,%lf,%lf",&x.&y,&z)!=EOF){
if((y/z/z)>=25)printf("%d\n",x);
}
return 0;
} | a.cc: In function 'int main()':
a.cc:7:29: error: expected unqualified-id before '&' token
7 | while(scanf("%d,%lf,%lf",&x.&y,&z)!=EOF){
| ^
|
s890129226 | p00075 | C++ | #include <iostream>
#include <cstdio>
using namespace std;
#define rep2(x,from,to) for(int x = (from); x < (to); ++(x))
#define rep(x,to) rep2(x,0,to)
int main() {
int n;
double w, h;
char a, b;
while(cin >> n >> a >> w >> b >> h) {
if(w/pow(h,2.0) >= 25) cout << n << endl;
}
return 0;
} | a.cc: In function 'int main()':
a.cc:12:22: error: 'pow' was not declared in this scope
12 | if(w/pow(h,2.0) >= 25) cout << n << endl;
| ^~~
|
s007011107 | p00075 | C++ | #include <iostream>
#include <string>
#include <vector>
#include <algorithm>
#include <utility>
#include <cstring>
#include <cmath>
#include <queue>
#include <map>
#include <set>
using namespace std;
#define rep(i,n) for(int i=0; i<n; i++)
#define FOR(i,s,n) for(int i=s; i<n; i++)
#define ALL(x) x.begin(), x.end()
#d... | a.cc: In member function 'float Person::bmi()':
a.cc:30:24: error: 'mass' was not declared in this scope
30 | return mass/h*h;
| ^~~~
a.cc: In function 'int main()':
a.cc:35:9: error: 'list' was not declared in this scope
35 | list<Person> pers;
| ... |
s410376607 | p00075 | C++ | #include <iostream>
#include <string>
#include <vector>
#include <algorithm>
#include <utility>
#include <cstring>
#include <cmath>
#include <queue>
#include <map>
#include <set>
using namespace std;
#define rep(i,n) for(int i=0; i<n; i++)
#define FOR(i,s,n) for(int i=s; i<n; i++)
#define ALL(x) x.begin(), x.end()
#d... | a.cc: In member function 'float Person::bmi()':
a.cc:30:24: error: 'mass' was not declared in this scope
30 | return mass/h*h;
| ^~~~
|
s676002114 | p00075 | C++ | #include <iostream>
#include <string>
#include <vector>
#include <algorithm>
#include <utility>
#include <cstring>
#include <cmath>
#include <queue>
#include <map>
#include <set>
using namespace std;
#define rep(i,n) for(int i=0; i<n; i++)
#define FOR(i,s,n) for(int i=s; i<n; i++)
#define ALL(x) x.begin(), x.end()
#d... | a.cc: In member function 'float Person::bmi()':
a.cc:30:24: error: 'mass' was not declared in this scope
30 | return mass/h*h;
| ^~~~
|
s801949250 | p00075 | C++ | #include <iostream>
#include <string>
#include <vector>
#include <algorithm>
#include <utility>
#include <cstring>
#include <cmath>
#include <queue>
#include <map>
#include <set>
using namespace std;
#define rep(i,n) for(int i=0; i<n; i++)
#define FOR(i,s,n) for(int i=s; i<n; i++)
#define ALL(x) x.begin(), x.end()
#d... | a.cc: In member function 'float Person::bmi()':
a.cc:30:24: error: 'mass' was not declared in this scope
30 | return mass/h*h;
| ^~~~
|
s593205201 | p00075 | C++ | #include <iostream>
#include <string>
#include <vector>
#include <algorithm>
#include <utility>
#include <cstring>
#include <cmath>
#include <queue>
#include <map>
#include <set>
using namespace std;
#define rep(i,n) for(int i=0; i<n; i++)
#define FOR(i,s,n) for(int i=s; i<n; i++)
#define ALL(x) x.begin(), x.end()
#d... | a.cc: In member function 'float Person::bmi()':
a.cc:31:24: error: 'mass' was not declared in this scope
31 | return mass/h*h;
| ^~~~
|
s828890802 | p00075 | C++ | #include <iostream>
#include <string>
#include <vector>
#include <algorithm>
#include <utility>
#include <cstring>
#include <cmath>
#include <queue>
#include <map>
#include <set>
using namespace std;
#define rep(i,n) for(int i=0; i<n; i++)
#define FOR(i,s,n) for(int i=s; i<n; i++)
#define ALL(x) x.begin(), x.end()
#d... | a.cc: In function 'int main()':
a.cc:35:22: error: aggregate 'std::stringstream str' has incomplete type and cannot be defined
35 | stringstream str;
| ^~~
|
s402706731 | p00075 | C++ | #include <iostream>
#include <string>
#include <vector>
#include <algorithm>
#include <utility>
#include <cstring>
#include <cmath>
#include <queue>
#include <map>
#include <set>
#include <sstream>
using namespace std;
#define rep(i,n) for(int i=0; i<n; i++)
#define FOR(i,s,n) for(int i=s; i<n; i++)
#define ALL(x) x.... | a.cc: In function 'int main()':
a.cc:37:18: error: no match for 'operator>>' (operand types are 'std::istream' {aka 'std::basic_istream<char>'} and 'std::stringstream' {aka 'std::__cxx11::basic_stringstream<char>'})
37 | while(cin>>str){
| ~~~^~~~~
| | |
| ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.