submission_id
stringlengths
10
10
problem_id
stringlengths
6
6
language
stringclasses
3 values
code
stringlengths
1
522k
compiler_output
stringlengths
43
10.2k
s771852087
p00004
C++
#include<iostream> #include<vector> #include<algorithm> #include<string> #include<sstream> #include<iomanip> #include<cstdlib> using namespace std; int main() { double a, b, c, d, e, f; while (cin >> a >> b >> c >> d >> e >> f) { double x = (c*e - b*f) / (a*e - b*d); double y = (c*d - a*f) / (b*d - a*e); if (...
a.cc: In function 'int main()': a.cc:17:32: error: 'fabs' was not declared in this scope; did you mean 'labs'? 17 | if (x == 0)x = fabs(x); | ^~~~ | labs a.cc:18:32: error: 'fabs' was not declared in this scope; did you mean 'l...
s152138630
p00004
C++
#include <cstdio> int main() { double a,b,c,d,e,f; while(scanf("%f %f %f %f %f %f",&a,&b,&c,&d,&e,&f)!=EOF){ prinff("%f %f\n",(c * e - b * f) / (a * e - b * d),(a*f-d*c)/(a*e-b*d)); }; return 0; };
a.cc: In function 'int main()': a.cc:5:3: error: 'prinff' was not declared in this scope; did you mean 'printf'? 5 | prinff("%f %f\n",(c * e - b * f) / (a * e - b * d),(a*f-d*c)/(a*e-b*d)); | ^~~~~~ | printf
s578761141
p00004
C++
#include <cstdio> int main() { double a,b,c,d,e,f; while(scanf("%lf %lf %lf %lf %lf %lf",&a,&b,&c,&d,&e,&f)!=EOF){ prinff("%lf %lf\n",(c * e - b * f) / (a * e - b * d),(a*f-d*c)/(a*e-b*d)); }; return 0; };
a.cc: In function 'int main()': a.cc:5:3: error: 'prinff' was not declared in this scope; did you mean 'printf'? 5 | prinff("%lf %lf\n",(c * e - b * f) / (a * e - b * d),(a*f-d*c)/(a*e-b*d)); | ^~~~~~ | printf
s242803709
p00004
C++
solve :: [Double] -> String solve [a,b,c,d,e,f] = (shows ((c*e-b*f)/(a*e-b*d)) " ") ++ (show $ (a*f-c*d)/(a*e-b*d)) main = getContents >>= mapM_ putStrLn . map solve . map (map read . words) . lines
a.cc:1:1: error: 'solve' does not name a type 1 | solve :: [Double] -> String | ^~~~~
s792250967
p00004
C++
solve :: [Double] -> String solve [a,b,c,d,e,f] = (shows ((c*e-b*f)/(a*e-b*d)) " ") ++ (show $ (a*f-c*d)/(a*e-b*d)) main = getContents >>= mapM_ putStrLn . map solve . map (map read . words) . lines
a.cc:1:1: error: 'solve' does not name a type 1 | solve :: [Double] -> String | ^~~~~
s767407336
p00004
C++
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { // TODO Auto-generated method stub BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); String line =""; while((li...
a.cc:2:1: error: 'import' does not name a type 2 | import java.io.BufferedReader; | ^~~~~~ a.cc:2:1: note: C++20 'import' only available with '-fmodules-ts' a.cc:3:1: error: 'import' does not name a type 3 | import java.io.IOException; | ^~~~~~ a.cc:3:1: note: C++20 'import' only available with '-fm...
s989209895
p00004
C++
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { // TODO Auto-generated method stub BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); String line =""; while((li...
a.cc:2:1: error: 'import' does not name a type 2 | import java.io.BufferedReader; | ^~~~~~ a.cc:2:1: note: C++20 'import' only available with '-fmodules-ts' a.cc:3:1: error: 'import' does not name a type 3 | import java.io.IOException; | ^~~~~~ a.cc:3:1: note: C++20 'import' only available with '-fm...
s707801729
p00004
C++
//#define _USE_MATH_DEFINES #define _CRT_SECURE_NO_WARNINGS #include <cstdio> //#include <cstdlib> //#include <cmath> #include <iostream> #include <algorithm> //#include <cstring> #include <vector> #include <string> #include <map> #include <list> #include <queue> #include <set> using namespace std; int main(void){ i...
a.cc: In function 'int main()': a.cc:25:21: error: 'round' was not declared in this scope 25 | x = round(x * 1000) / 1000; | ^~~~~
s736715416
p00004
C++
#include <cstdio> #include <vector> using namespace std; int main(){ double a,b,c,d,e,f; vector<double> out; while (scanf("%f %f %f %f %f %f",&a,&b,&c,&d,&e,&f)!=EOF){ out.push_back((c*e-b*f)/(a*e-b*d)); out.push_back((c*d-a*f)/(b*d-a*e)); } for (int i=0;i<out.size();i+=2){ printf("%f %f\n",roun...
a.cc: In function 'int main()': a.cc:14:22: error: 'round' was not declared in this scope 14 | printf("%f %f\n",round(out[i]*1000)/1000.0,round(out[i+1]*1000)/1000.0); | ^~~~~
s744759700
p00004
C++
#include<iostream> using namespce std; int main() { int a,b,c,d,e,f; double x,y; while(cin>>a>>b>>c>>d>>e>>f){ double l,m,n; l=a/d; m=b-e*l; n=c-f*l; y=n/m; x=(c-by)/a; cout<<x<<" "<<y<<endl; } return 0; }
a.cc:2:7: error: expected nested-name-specifier before 'namespce' 2 | using namespce std; | ^~~~~~~~ a.cc: In function 'int main()': a.cc:8:11: error: 'cin' was not declared in this scope; did you mean 'std::cin'? 8 | while(cin>>a>>b>>c>>d>>e>>f){ | ^~~ | std::cin...
s261367741
p00004
C++
#include<iostream> using namespace std; int main() { int a,b,c,d,e,f; double x,y; while(cin>>a>>b>>c>>d>>e>>f){ double l,m,n; l=a/d; m=b-e*l; n=c-f*l; y=n/m; x=(c-by)/a; cout<<x<<" "<<y<<endl; } return 0; }
a.cc: In function 'int main()': a.cc:14:14: error: 'by' was not declared in this scope; did you mean 'y'? 14 | x=(c-by)/a; | ^~ | y
s726837808
p00004
C++
#include<iostream> using namespace std; int main() { int a,b,c,d,e,f; double x,y; for(int i=0;i<2;i++){ cin>>a>>b>>c>>d>>e>>f double l,m,n; l=a/d; m=b-e*l; n=c-f*l; y=n/m; x=(c-b*y)/a; cout<<x<<" "<<y<<endl; } return 0; }
a.cc: In function 'int main()': a.cc:9:30: error: expected ';' before 'double' 9 | cin>>a>>b>>c>>d>>e>>f | ^ | ; 10 | double l,m,n; | ~~~~~~ a.cc:11:9: error: 'l' was not declared in this scope ...
s477599539
p00004
C++
#include<iostream> #include<cstio> using namespace std; int main() { int a,b,c,d,e,f; double x,y; while(cin>>a>>b>>c>>d>>e>>f){ y=(a*f-c*d)/(a*e-d*b); x=(c-b*y)/a; printf("%.3f %.3f\n",x,y); } return 0; }
a.cc:2:9: fatal error: cstio: No such file or directory 2 | #include<cstio> | ^~~~~~~ compilation terminated.
s685627057
p00004
C++
#include <iostream> using namespace std; int main() { int a, b, c, d, e, f; while (cin >> a >> b >> c >> d >> e >> f) { printf("%.3f %.3f, (a * f - c * d) / (a * e - b * d), (b * f - c * e) / (b * d - a * e)); } return 0; }
a.cc:6:12: warning: missing terminating " character 6 | printf("%.3f %.3f, (a * f - c * d) / (a * e - b * d), (b * f - c * e) / (b * d - a * e)); | ^ a.cc:6:12: error: missing terminating " character 6 | printf("%.3f %.3f, (a * f - c * d) / (a * e - b * d), (b * f - c * e) / (b * d - a ...
s051957212
p00004
C++
#include <iostream> #include <stdio> using namespace std; int main() { double a,b,c,d,e,f; while(cin>>a>>b>>c>>d>>e>>f) { printf("%.3f %.3f\n", (b*f - c*e)/(b*d - a*e)+0.0001, (a*f - c*d)/(a*e - b*d)+0.0001); } return 0; }
a.cc:2:10: fatal error: stdio: No such file or directory 2 | #include <stdio> | ^~~~~~~ compilation terminated.
s046914906
p00004
C++
#include <iostream> #include <cstdio> using namespace std; int main() { double a,b,c,d,e,f; while(cin>>a>>b>>c>>d>>e>>f) { printf("%.3f %.3f\n", round((1.0 * b*f - c*e)/(b*d - a*e) * 1000) / 1000, round((1.0 * a*f - c*d)/(a*e - b*d) * 1000) / 1000); } return 0; }
a.cc: In function 'int main()': a.cc:9:23: error: 'round' was not declared in this scope 9 | printf("%.3f %.3f\n", round((1.0 * b*f - c*e)/(b*d - a*e) * 1000) / 1000, round((1.0 * a*f - c*d)/(a*e - b*d) * 1000) / 1000); | ^~~~~
s527797017
p00004
C++
File Edit Options Buffers Tools C++ Help #include <iostream> #include <iomanip> #include <cmath> using namespace std; #define RENT 100000 int main(){ int n; int cnt=0; float a, b, c, d, e, f; while(cin >> a >> b >> c >> d >> e >> f){ float detA = a*e - b*d; ...
a.cc:1:1: error: 'File' does not name a type 1 | File Edit Options Buffers Tools C++ Help | ^~~~ In file included from /usr/include/c++/14/iosfwd:42, from /usr/include/c++/14/ios:40, from /usr/include/c++/14/ostream:40, from /usr/include/c++/14/iostream:41, ...
s296261205
p00004
C++
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ConsoleApplication3 { class Program { static void Main(string[] args) { while (true) { double x, y; double[] h = ...
a.cc:1:7: error: expected nested-name-specifier before 'System' 1 | using System; | ^~~~~~ a.cc:2:7: error: expected nested-name-specifier before 'System' 2 | using System.Collections.Generic; | ^~~~~~ a.cc:3:7: error: expected nested-name-specifier before 'System' 3 | using System.L...
s550788407
p00004
C++
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ConsoleApplication3 { class Program { static void Main(string[] args) { while (true) { double x, y; double[] h = ...
a.cc:1:7: error: expected nested-name-specifier before 'System' 1 | using System; | ^~~~~~ a.cc:2:7: error: expected nested-name-specifier before 'System' 2 | using System.Collections.Generic; | ^~~~~~ a.cc:3:7: error: expected nested-name-specifier before 'System' 3 | using System.L...
s094355243
p00004
C++
using System; using System.Collections.Generic; using System.Linq; using System.Text; class Program { static void Main(string[] args) { while (true) { double x, y; double[] h = new double[6]; String str = Console.ReadLine()...
a.cc:1:7: error: expected nested-name-specifier before 'System' 1 | using System; | ^~~~~~ a.cc:2:7: error: expected nested-name-specifier before 'System' 2 | using System.Collections.Generic; | ^~~~~~ a.cc:3:7: error: expected nested-name-specifier before 'System' 3 | using System.L...
s824788935
p00004
C++
#include <iostream> #include <algorithm> using namespace std; int main(){ double a, b, c, d, e, f; double x, y; cin >> a >> b >> c >> d >> e >> f; x == (c*e - b*f) / (a*e - b*d); y == (c - a*x) / b; cout >> fixed >> setprecision(3) >> x >> " " >> y >> endl; //printf("%.3f %.3f\n", x, y); }
a.cc: In function 'int main()': a.cc:15:14: error: no match for 'operator>>' (operand types are 'std::ostream' {aka 'std::basic_ostream<char>'} and 'std::ios_base&(std::ios_base&)') 15 | cout >> fixed >> setprecision(3) >> x >> " " >> y >> endl; | ~~~~ ^~ ~~~~~ | | | |...
s286147301
p00004
C++
#include <iostream> #include <algorithm> using namespace std; int main(){ double a, b, c, d, e, f; double x, y; cin >> a >> b >> c >> d >> e >> f; x == (c*e - b*f) / (a*e - b*d); y == (c - a*x) / b; cout << fixed << setprecision(3) << x << " " << y << endl; //printf("%.3f %.3f\n", x, y); }
a.cc: In function 'int main()': a.cc:15:26: error: 'setprecision' was not declared in this scope 15 | cout << fixed << setprecision(3) << x << " " << y << endl; | ^~~~~~~~~~~~ a.cc:3:1: note: 'std::setprecision' is defined in header '<iomanip>'; this is probably fixable by addi...
s727532844
p00004
C++
#include <iostream> #include <algorithm> using namespace std; int main(){ double a, b, c, d, e, f; double x, y; cin >> a >> b >> c >> d >> e >> f; x == (c*e - b*f) / (a*e - b*d); y == (c - a*x) / b; cout << fixed << setprecision(3) << x << " " << y << endl; //printf("%.3f %.3f\n", x, y); }
a.cc: In function 'int main()': a.cc:15:26: error: 'setprecision' was not declared in this scope 15 | cout << fixed << setprecision(3) << x << " " << y << endl; | ^~~~~~~~~~~~ a.cc:3:1: note: 'std::setprecision' is defined in header '<iomanip>'; this is probably fixable by addi...
s206511534
p00004
C++
#include<stdio.h> #include<stdlib.h> #include<iostream> #include<string> #include<vector> #include<math.h> #include<queue> #include <algorithm> #include<functional> #include<cstdlib> #include<cmath> #define REP(i, n) for(int i = 0;i < n;i++) #define REPR(i, n) for(int i = n;i >= 0;i--) #define FOR(i, m, n) for(int i ...
a.cc: In function 'int main()': a.cc:68:16: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'? 68 | while (scanf_s("%d%d%d%d%d%d", &a, &b, &c, &d, &e, &f) != EOF) { | ^~~~~~~ | scanf
s262762816
p00004
C++
#include <algorithm> #include <vector> #include <math.h> #include <stdio.h> #include <cctype> #include <iostream> #include <set> #include <string> #include <queue> #include <map> using namespace std; int size(string x){ string::size_type size=x.size(); return size; } #define fu(l,k) for(int i=l;i<k;i++) #define fd(l...
a.cc: In function 'int main()': a.cc:33:30: error: expected primary-expression before '/' token 33 | x=(f-e*y)/d;*/ | ^ a.cc:34:17: error: expected primary-expression before 'double' 34 | double det = a*e - b * d; | ^~~~~~ a....
s355404078
p00004
C++
#include <iostream> using namespace std; int main(){ double a, b, c, d, e, f; double x, y; while(cin >> a >> b >> c >> d >> e >> f){ x = (c*e - b*f) / (a*e - b*d); y = (c*d - a*f) / (b*d - a*e); cout << fixed << setprecision(3) << x << " " << endl; } }
a.cc: In function 'int main()': a.cc:14:26: error: 'setprecision' was not declared in this scope 14 | cout << fixed << setprecision(3) << x << " " << endl; | ^~~~~~~~~~~~ a.cc:2:1: note: 'std::setprecision' is defined in header '<iomanip>'; this is probably fixable by adding '#...
s684290375
p00004
C++
#include<iostream> #include<iomanip> using namespace std; int main(){ float a, b, c, d, e, f, x, y; while(cin >> a >> b >> c >> d >> e >> f){ x = (b * f - c * e) / (b * d - a * e); y = (c - a * x) / b; } if(x > 0) { x += 0.0005; } else(x < 0){ x -= 0.0005; } if(y > 0){ y += 0.0005; } else(y < 0){ ...
a.cc: In function 'int main()': a.cc:14:20: error: expected ';' before '{' token 14 | else(x < 0){ | ^ | ; a.cc:20:20: error: expected ';' before '{' token 20 | else(y < 0){ | ^ | ;
s948251846
p00004
C++
#include<iostream> #include<algorithm> using namespace std; int main() { double a,b,c,d,e,f; double x,y; while(cin>>a>>b>>c>>d>>e>>f){ x=(double)((e*c-b*f)/(a*e-b*d)); y = (double)((-(d*c)+a*f) / (a*e-b*d)); if(x == 0){x = 0;} if(y == 0){y = 0;} printf("%.3f %.3f\n",x,y); return 0; }
a.cc: In function 'int main()': a.cc:17:2: error: expected '}' at end of input 17 | } | ^ a.cc:6:1: note: to match this '{' 6 | { | ^
s573488323
p00004
C++
#include<iostream> using namespace std; int main() { double a,b,c,d,e,f; double x,y; while(cin>>a>>b>>c>>d>>e>>f){ x=(double)((e*c-b*f)/(a*e-b*d)); y = (double)((-(d*c)+a*f) / (a*e-b*d)); if(x == 0){x = 0;} if(y == 0){y = 0;} printf("%.3f %.3f\n",x,y); return 0; }
a.cc: In function 'int main()': a.cc:16:2: error: expected '}' at end of input 16 | } | ^ a.cc:5:1: note: to match this '{' 5 | { | ^
s443265665
p00004
C++
#include<iostream> using namespace std; int main() { double a,b,c,d,e,f; double x,y; while(cin>>a>>b>>c>>d>>e>>f){ x=(double)((e*c-b*f)/(a*e-b*d)); y = (double)((-(d*c)+a*f) / (a*e-b*d)); if(x == 0){x = 0;} if(y == 0){y = 0;} printf("%.3f %.3f\n",x,y); return 0; }
a.cc: In function 'int main()': a.cc:16:2: error: expected '}' at end of input 16 | } | ^ a.cc:5:1: note: to match this '{' 5 | { | ^
s725389023
p00004
C++
using namespace std; int main() { double a, b, c, d, e, f; while (cin >> a >> b >> c >> d >> e >> f) { b = b * d / a; c = c * d / a; a = a * d / a; d = d - a; // d = 0 e = e - b; f = f - c; f = f * b / e; e = e * b / e; b = b - e; // b = 0 c = c - f; c = c / a; ...
a.cc: In function 'int main()': a.cc:7:16: error: 'cin' was not declared in this scope 7 | while (cin >> a >> b >> c >> d >> e >> f) | ^~~ a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>' +++ |+#include <iostream> ...
s715021842
p00004
C++
#include <iostream> using namespace std; int main() { double a, b, c, d, e, f; while (cin >> a >> b >> c >> d >> e >> f) { b = b * d / a; c = c * d / a; a = a * d / a; d = d - a; // d = 0 e = e - b; f = f - c; f = f * b / e; ...
a.cc: In function 'int main()': a.cc:31:26: error: 'setprecision' was not declared in this scope 31 | cout << fixed << setprecision(3) << c << " " << fixed << setprecision(3) << f << endl; | ^~~~~~~~~~~~ a.cc:2:1: note: 'std::setprecision' is defined in header '<iomanip>'; this...
s464870586
p00004
C++
#include<cstdio> using namespace std; int main() { int a, b, c, d, e, f; double x, y; char line[200]; while(fgets(line, 200, stdin) != NULL) { sscanf(line, "%d%d%d%d%d%d", &a, &b, &c, &d, &e, &f); x = ((double)(e*c - b*f)) / (a*e - d*b); ...
a.cc: In function 'int main()': a.cc:13:20: error: 'abs' was not declared in this scope 13 | if(abs(x) < 1.0e-4) x = 0; | ^~~ a.cc:14:20: error: 'abs' was not declared in this scope 14 | if(abs(y) < 1.0e-4) y = 0; | ^~~
s568254759
p00004
C++
import java.util.Scanner; public class main{ static int a,b,c,d,e,f; static double x,y; public static void main(String[] args) { Scanner s = new Scanner(System.in); while(true){ a = s.nextInt(); b = s.nextInt(); c = s.nextInt(); d = s.nextInt(); e = s.nextInt(); f = s.nextInt(); x = (e*c-b*f)/(a+e...
a.cc:2:1: error: 'import' does not name a type 2 | import java.util.Scanner; | ^~~~~~ a.cc:2:1: note: C++20 'import' only available with '-fmodules-ts' a.cc:3:1: error: expected unqualified-id before 'public' 3 | public class main{ | ^~~~~~
s780562187
p00004
C++
#include <iostream> using namespace std; int main() { int i; double a[2], b[2], c[2], x, y; cin >> a[0] >> b[0] >> c[0] >> a[1] >> b[1] >> c[1]; if (a[0] == 0) { y = c[0] / b[0]; x = (c[1] - b[1] * y) / a[1]; } else if (b[0] == 0) { x = c[0] / a[0]; y = (c[1] - a[1] * x) / b[1]; } else if (a[1] == 0) { ...
a.cc: In function 'int main()': a.cc:27:17: error: 'pow' was not declared in this scope 27 | x = x * pow(10,3); | ^~~ a.cc:28:13: error: 'round' was not declared in this scope 28 | x = round(x); | ^~~~~
s288722815
p00004
C++
#include <iostream> using namespace std; int main() { int i; double a[2], b[2], c[2], x, y; cin >> a[0] >> b[0] >> c[0] >> a[1] >> b[1] >> c[1]; if (a[0] == 0) { y = c[0] / b[0]; x = (c[1] - b[1] * y) / a[1]; } else if (b[0] == 0) { x = c[0] / a[0]; y = (c[1] - a[1] * x) / b[1]; } else if (a[1] == 0) { ...
a.cc: In function 'int main()': a.cc:27:17: error: 'pow' was not declared in this scope 27 | x = x * pow(10,3); | ^~~ a.cc:28:13: error: 'round' was not declared in this scope 28 | x = round(x); | ^~~~~
s060017573
p00004
C++
#include <iostream> #include <stdio.h> using namespace std; int main() { double a, b, c, d, e, f; double x, y; double det; while (cin >> a >> b >> c >> d >> e >> f) { det = a * e - b * d; x = (e * c - b * f) / det;a y = (-d * c + a * f) / det; printf("%.3f %.3f\n", x, y); } }
a.cc: In function 'int main()': a.cc:11:44: error: expected ';' before 'y' 11 | x = (e * c - b * f) / det;a | ^ | ; 12 | y = (-d * c + a * f) / det; | ~ ...
s455179847
p00004
C++
#include<stdio.h> int main(void) { int b,a,e,d,f,i,c; float y,x; while(scanf("%d %d %d %d %d %d",&a,&b,&c,&d,&e,&f)!=EOF) { y=(c*d-a*f)/(b*d-a*e); x=(c-(b*y))/a; if(x<0.0000 && x>-0.0001){ x=; } if(y<0.000&&y>-0.0001){ y=0; } printf("%.3f %.3f\n",x,y); } return 0; }
a.cc: In function 'int main()': a.cc:10:27: error: expected primary-expression before ';' token 10 | x=; | ^
s115702276
p00004
C++
#include<stdio.h> main(){ double a,b,c,d,e,f; while(scanf("%lf %lf %lf %lf %lf %lf",&a,&b,&c,&d,&e,&f)==""){ printf("%f %f\n",(c*e-b*f)/(a*e-b*d),(a*f-c*d)/(a*e-b*d)); } }
a.cc:2:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type] 2 | main(){ | ^~~~ a.cc: In function 'int main()': a.cc:4:59: error: ISO C++ forbids comparison between pointer and integer [-fpermissive] 4 | while(scanf("%lf %lf %lf %lf %lf %lf",&a,&b,&c,&d,&e,&f)==""){ | ...
s042380105
p00004
C++
#include<stdio.h> main(){ double a,b,c,d,e,f; while(scanf("%lf %lf %lf %lf %lf %lf",&a,&b,&c,&d,&e,&f)!="EOF"){ printf("%f %f\n",(c*e-b*f)/(a*e-b*d),(a*f-c*d)/(a*e-b*d)); } }
a.cc:2:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type] 2 | main(){ | ^~~~ a.cc: In function 'int main()': a.cc:4:59: error: ISO C++ forbids comparison between pointer and integer [-fpermissive] 4 | while(scanf("%lf %lf %lf %lf %lf %lf",&a,&b,&c,&d,&e,&f)!="EOF"){ | ...
s853118515
p00004
C++
#include<stdio.h> main(){ double a,b,c,d,e,f,x,y; while(scanf("%lf %lf %lf %lf %lf %lf",&a,&b,&c,&d,&e,&f)!="EOF"){ x = (c*e-b*f)/(a*e-b*d); y = (a*f-c*d)/(a*e-b*d); printf("%f %f\n",x,y); } }
a.cc:2:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type] 2 | main(){ | ^~~~ a.cc: In function 'int main()': a.cc:4:59: error: ISO C++ forbids comparison between pointer and integer [-fpermissive] 4 | while(scanf("%lf %lf %lf %lf %lf %lf",&a,&b,&c,&d,&e,&f)!="EOF"){ | ...
s076425853
p00004
C++
main(){ double a,b,c,d,e,f,t; for(;scanf("%lf%lf%lf&lf%lf%lf",&a,&b,&c,&d,&e,&f)==6;){ t=a*e-b*d; printf("%.3lf%.3lf\n",(e*c-b*f)/t+0.0,(a*f-d*c)/t+0.0); } return 0; }
a.cc:1:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type] 1 | main(){ | ^~~~ a.cc: In function 'int main()': a.cc:3:10: error: 'scanf' was not declared in this scope 3 | for(;scanf("%lf%lf%lf&lf%lf%lf",&a,&b,&c,&d,&e,&f)==6;){ | ^~~~~ a.cc:5:9: error: 'printf...
s567524902
p00004
C++
main(){ double a,b,c,d,e,f,t; for(;scanf("%lf%lf%lf&lf%lf%lf",&a,&b,&c,&d,&e,&f)==6;){ t=a*e-b*d; printf("%.3lf%.3lf\n",(e*c-b*f)/t+0.0,(a*f-d*c)/t+0.0); } return 0; }
a.cc:1:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type] 1 | main(){ | ^~~~ a.cc: In function 'int main()': a.cc:3:10: error: 'scanf' was not declared in this scope 3 | for(;scanf("%lf%lf%lf&lf%lf%lf",&a,&b,&c,&d,&e,&f)==6;){ | ^~~~~ a.cc:5:9: error: 'printf...
s606167480
p00004
C++
import java.util.Scanner; public class Main { public static void main(String[] args){ //??\???a,b,c,d,e,f Scanner scan = new Scanner(System.in); //??£???????¨????ax+by=c, dx+ey=f???x,y????±??????? int a = scan.nextInt(); int b = scan.nextInt(); int c = scan.nextInt(); int d = scan.nextInt(); int e = sc...
a.cc:1:1: error: 'import' does not name a type 1 | import java.util.Scanner; | ^~~~~~ a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts' a.cc:2:1: error: expected unqualified-id before 'public' 2 | public class Main | ^~~~~~
s885978019
p00004
C++
import sys for line in sys.stdin: a,b,c,d,e,f = [float(w) for w in line.split()] print("{:.3f} {:.3f}".format((e*c-b*f)/(a*e-a*b), (d*c-a*f)/(b*d-a*e)))
a.cc:1:1: error: 'import' does not name a type 1 | import sys | ^~~~~~ a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts'
s700473294
p00004
C++
#include<iostream> #include <iomanip> using namespace std; int main(){ double a,b,j,d,e,f,a_,b_,c_,d_,e_,f_; double x,y; double in; while (std::cin >>a>>b>>c>>d>>e>>f){ in_ = (a*e - b*d); a_ = a/in; b_ = -1*d/in; d = -1*b/in; e_ = e/in; x = c * a_ + f*b_; y = c*d_ + f*e_; std::cout << std::setprecision(3) << x << ' ' ...
a.cc: In function 'int main()': a.cc:9:25: error: 'c' was not declared in this scope 9 | while (std::cin >>a>>b>>c>>d>>e>>f){ | ^ a.cc:10:1: error: 'in_' was not declared in this scope; did you mean 'in'? 10 | in_ = (a*e - b*d); | ^~~ | in
s039650499
p00004
C++
#include<iostream> #include <iomanip> using namespace std; int main(){ double a,b,j,d,e,f,a_,b_,c_,d_,e_,f_; double x,y; double in; while (std::cin >>a>>b>>c>>d>>e>>f){ in = (a*e - b*d); a_ = a/in; b_ = -1*d/in; d = -1*b/in; e_ = e/in; x = c * a_ + f*b_; y = c*d_ + f*e_; std::cout << std::setprecision(3) << x << ' ' <...
a.cc: In function 'int main()': a.cc:9:25: error: 'c' was not declared in this scope 9 | while (std::cin >>a>>b>>c>>d>>e>>f){ | ^
s827571764
p00004
C++
#include<iostream> #include <iomanip> using namespace std; int main(){ double a,b,c,d,e,f,a_,b_,c_,d_,e_,f_; double x,y; double in; while (std::cin >>a>>b>>c>>d>>e>>f){ in = (a*e - b*d); a_ = a/in; b_ = -1*d/in; d = -1*b/in; e_ = e/in; x = c * a_ + f*b_; y = c*d_ + f*e_; std::cout << std::setprecision(3) << std::fixed...
a.cc: In function 'int main()': a.cc:17:92: error: expected unqualified-id before '<<' token 17 | std::cout << std::setprecision(3) << std::fixed << x << ' ' << std::setprecision(3) <<std::<<fixed << y << std::endl; | ^...
s067974072
p00004
C++
#include<iostream> #include <iomanip> int main(){ double a,b,c,d,e,f,a_,b_,c_,d_,e_,f_; double x,y; double in; while (std::cin >>a>>b>>c>>d>>e>>f){ in = (a*e - b*d); a_ = a/in; b_ = -1*d/in; d = -1*b/in; e_ = e/in; x = c * a_ + f*b_; y = c*d_ + f*e_; std::cout << std::setprecision(3) << std::fixed << x << ' ' << std::...
a.cc: In function 'int main()': a.cc:16:92: error: expected unqualified-id before '<<' token 16 | std::cout << std::setprecision(3) << std::fixed << x << ' ' << std::setprecision(3) <<std::<< std::fixed << y << std::endl; | ...
s872009882
p00004
C++
#include<stdio.h> #include <stdlib.h> #include<math.h> int main(){ char buf[18]; double a,b,c,d,e,f,x,y; while(fgets(buf,sizeof(buf),stdin)!=NULL){ sscanf_s(buf,"%lf %lf %lf %lf %lf %lf",&a,&b,&c,&d,&e,&f); x=(b*f-c*e)/(b*d-a*e); y=-1.0*(x*a-c)/b; printf("%.3lf %.3lf\n",x==0.0 ? fabs(x) : x, y==0.0 ? fabs(y...
a.cc: In function 'int main()': a.cc:9:17: error: 'sscanf_s' was not declared in this scope; did you mean 'sscanf'? 9 | sscanf_s(buf,"%lf %lf %lf %lf %lf %lf",&a,&b,&c,&d,&e,&f); | ^~~~~~~~ | sscanf
s350659994
p00004
C++
#include <iostream> using namespace std; int main() { int a, b, c, d, e, f; double x, y; while (cin >> a >> b >> c >> d >> e >> f) { b *= d; c *= d; e *= a; f *= a; b -= e; c -= f; y = c*1.0 / b; x = (f - e*y)*1.0 / (d*a); if (x < 0.0001 && x > -0.0001) x = 0.000; if (y < 0.0001 && y > -0.0001) y = 0...
a.cc: In function 'int main()': a.cc:17:34: error: 'setprecision' was not declared in this scope 17 | cout << fixed << setprecision(3) << x << " " << fixed << setprecision(3) << y << endl; | ^~~~~~~~~~~~ a.cc:2:1: note: 'std::setprecision' is defined in header '...
s303208003
p00004
C++
#include <iostream> using namespace std; int main() { int a, b, c, d, e, f; double x, y; while (cin >> a >> b >> c >> d >> e >> f) { b *= d; c *= d; e *= a; f *= a; b -= e; c -= f; y = c*1.0 / b; x = (f - e*y)*1.0 / (d*a); if (x < 0.0001 && x > -0.0001) x = 0.000; if (y < 0.0001 && y > -0.0001) y = 0...
a.cc: In function 'int main()': a.cc:17:34: error: 'setprecision' was not declared in this scope 17 | cout << fixed << setprecision(3) << x << " " << fixed << setprecision(3) << y << endl; | ^~~~~~~~~~~~ a.cc:2:1: note: 'std::setprecision' is defined in header '...
s688123168
p00004
C++
#include <stdio.h> int main(){ int a, b, c, d, e, f; std::cin >> a; std::cin >> b; std::cin >> c; std::cin >> d; std::cin >> e; std::cin >> f; double x, y; x = (c*e-b*f) / (a*e-b*d); y = (a*f-c*d) / (a*e-b*d); printf("%f.3 %f.3\n", x, y); return 0; }
a.cc: In function 'int main()': a.cc:5:8: error: 'cin' is not a member of 'std' 5 | std::cin >> a; | ^~~ a.cc:2:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>' 1 | #include <stdio.h> +++ |+#include <iostream> 2 | a.cc:6:8: err...
s387620060
p00004
C++
#include <stdio.h> int main(){ int a, b, c, d, e, f; scanf("%d",&a); scanf("%d",&b); scanf("%d",&c); scanf("%d",&d); scanf("%d",&e); scanf("%d",&f); double x, y; x = (double)(c*e-b*f) / (double)(a*e-b*d); y = (double)(a*f-c*d) / (double)(a*e-b*d); ???x = (double)round(x*10000.0) / 10000.0; y =...
a.cc: In function 'int main()': a.cc:15:1: error: expected primary-expression before '?' token 15 | ???x = (double)round(x*10000.0) / 10000.0; | ^ a.cc:15:2: error: expected primary-expression before '?' token 15 | ???x = (double)round(x*10000.0) / 10000.0; | ^ a.cc:15:3: error: expected primary-expr...
s890410415
p00004
C++
#include <stdio.h> int main(){ int a, b, c, d, e, f; scanf("%d",&a); scanf("%d",&b); scanf("%d",&c); scanf("%d",&d); scanf("%d",&e); scanf("%d",&f); double x, y; x = (double)(c*e-b*f) / (double)(a*e-b*d); y = (double)(a*f-c*d) / (double)(a*e-b*d); ???x = (double)round(x*10000.0) / 10000.0; y =...
a.cc: In function 'int main()': a.cc:15:1: error: expected primary-expression before '?' token 15 | ???x = (double)round(x*10000.0) / 10000.0; | ^ a.cc:15:2: error: expected primary-expression before '?' token 15 | ???x = (double)round(x*10000.0) / 10000.0; | ^ a.cc:15:3: error: expected primary-expr...
s898794888
p00004
C++
#include <stdio.h> int main(){ int a, b, c, d, e, f; scanf("%d",&a); scanf("%d",&b); scanf("%d",&c); scanf("%d",&d); scanf("%d",&e); scanf("%d",&f); double x, y; x = (double)(c*e-b*f) / (double)(a*e-b*d); y = (double)(a*f-c*d) / (double)(a*e-b*d); ???x = (double)round(x*10000.0) / 10000.0; y =...
a.cc: In function 'int main()': a.cc:15:1: error: expected primary-expression before '?' token 15 | ???x = (double)round(x*10000.0) / 10000.0; | ^ a.cc:15:2: error: expected primary-expression before '?' token 15 | ???x = (double)round(x*10000.0) / 10000.0; | ^ a.cc:15:3: error: expected primary-expr...
s273771569
p00004
C++
#include <stdio.h> int main(){ int a, b, c, d, e, f; scanf("%d",&a); scanf("%d",&b); scanf("%d",&c); scanf("%d",&d); scanf("%d",&e); scanf("%d",&f); double x, y; x = (double)(c*e-b*f) / (double)(a*e-b*d); y = (double)(a*f-c*d) / (double)(a*e-b*d); x = (double)round(x*10000.0) / 10000.0; y = ...
a.cc: In function 'int main()': a.cc:15:15: error: 'round' was not declared in this scope 15 | x = (double)round(x*10000.0) / 10000.0; | ^~~~~
s833427825
p00004
C++
#include <stdio.h> #include <math.h> int main(){ int i = 0; while(1){ i++; int a, b, c, d, e, f; scanf("%d ",&a); scanf("%d ",&b); scanf("%d ",&c); scanf("%d ",&d); scanf("%d ",&e); scanf("%d ",&f); double x, y; x = (double)(c*e-b*f) / (double)(a*e-b*d); y = (double)(a*f-c*d) / (double)(a*...
a.cc: In function 'int main()': a.cc:23:11: error: too few arguments to function 'int scanf(const char*, ...)' 23 | if(scanf()==EOF) break; | ~~~~~^~ In file included from /usr/include/features.h:523, from /usr/include/x86_64-linux-gnu/bits/libc-header-start.h:33, from ...
s061317447
p00004
C++
#include <stdio.h> #include <math.h> int main(){ int i = 0; while(1){ i++; int a, b, c, d, e, f; scanf("%d ",&a); scanf("%d ",&b); scanf("%d ",&c); scanf("%d ",&d); scanf("%d ",&e); scanf("%d ",&f); double x, y; x = (double)(c*e-b*f) / (double)(a*e-b*d); y = (double)(a*f-c*d) / (double)(a*...
a.cc: In function 'int main()': a.cc:26:5: error: expected ',' or ';' before 'fseek' 26 | fseek(STDIN, lineL, SEEK_SET); | ^~~~~
s864818357
p00004
C++
#include <stdio.h> #include <math.h> int main(){ int i = 0; while(1){ i++; int a, b, c, d, e, f; scanf("%d ",&a); scanf("%d ",&b); scanf("%d ",&c); scanf("%d ",&d); scanf("%d ",&e); scanf("%d ",&f); double x, y; x = (double)(c*e-b*f) / (double)(a*e-b*d); y = (double)(a*f-c*d) / (double)(a*...
a.cc: In function 'int main()': a.cc:26:11: error: 'STDIN' was not declared in this scope 26 | fseek(STDIN, lineL, SEEK_SET); | ^~~~~ a.cc:26:18: error: 'lineL' was not declared in this scope; did you mean 'line'? 26 | fseek(STDIN, lineL, SEEK_SET); | ^~~~~ | ...
s885599756
p00004
C++
#include <stdio.h> #include <math.h> int main(){ int i = 0; while(1){ i++; int a, b, c, d, e, f; scanf("%d ",&a); scanf("%d ",&b); scanf("%d ",&c); scanf("%d ",&d); scanf("%d ",&e); scanf("%d ",&f); double x, y; x = (double)(c*e-b*f) / (double)(a*e-b*d); y = (double)(a*f-c*d) / (double)(a*...
a.cc: In function 'int main()': a.cc:26:18: error: 'lineL' was not declared in this scope; did you mean 'line'? 26 | fseek(stdin, lineL, SEEK_SET); | ^~~~~ | line
s226680410
p00004
C++
#include <stdio.h> #include <math.h> int main(){ int i = 0; int a, b, c, d, e, f; while(scanf("%d", &a)!=EOF){ i++; scanf("%d ",&b); scanf("%d ",&c); scanf("%d ",&d); scanf("%d ",&e); scanf("%d ",&f); double x, y; x = (double)(c*e-b*f) / (double)(a*e-b*d); y = (double)(a*f-c*d) / (double)(a...
a.cc: In function 'int main()': a.cc:27:2: error: expected '}' at end of input 27 | } | ^ a.cc:4:11: note: to match this '{' 4 | int main(){ | ^
s609355938
p00004
C++
#include <stdio.h> #include <math.h> int main(){ int i = 0; int a, b, c, d, e, f; while(scanf("%d", &a)!=EOF){ i++; scanf("%d ",&b); scanf("%d ",&c); scanf("%d ",&d); scanf("%d ",&e); scanf("%d ",&f); double x, y; x = (double)(c*e-b*f) / (double)(a*e-b*d); y = (double)(a*f-c*d) / (double)(a...
a.cc: In function 'int main()': a.cc:22:18: error: expected ';' before '}' token 22 | scanf("%d", &a) | ^ | ; 23 | } | ~
s300434458
p00004
C++
#include <iostream> using namespace std; float main(){ int a, b, c, d, e; while(cin >> a >> b >> c >> d >> e){ float x, y; x = (float)(b*f - c*e)/(b*d -a*e); y = (float)(c - a*x)/b; cout << x << " " << y << endl; } return 0; }
a.cc:4:1: error: '::main' must return 'int' 4 | float main(){ | ^~~~~ a.cc: In function 'int main()': a.cc:9:31: error: 'f' was not declared in this scope 9 | x = (float)(b*f - c*e)/(b*d -a*e); | ^
s267037064
p00004
C++
#include <iostream> using namespace std; float main(){ int a, b, c, d, e, f; while(cin >> a >> b >> c >> d >> e >> f){ float x, y; x = (float)(b*f - c*e)/(b*d -a*e); y = (float)(c - a*x)/b; cout << x << " " << y << endl; } return 0; }
a.cc:4:1: error: '::main' must return 'int' 4 | float main(){ | ^~~~~
s578511498
p00004
C++
#include <iostream> #include <stdio.h> using namespace std; int main(){ int a,b,c,d,e,f; float x , y , delta; while(cin >> a >> b >> c >> d >> e >> f){ delta = (a * e) - (b * d); x = ((c * e) - (b * f)) / delta; y = ((a * f) - (c * d)) / delta; if(x % 10000 >= 5){ x += 0.001; }if(y % 10000 >=...
a.cc: In function 'int main()': a.cc:16:30: error: invalid operands of types 'float' and 'int' to binary 'operator%' 16 | if(x % 10000 >= 5){ | ~ ^ ~~~~~ | | | | | int | ...
s250875905
p00004
C++
#include <iostream> #include <stdio.h> using namespace std; int main(){ int a,b,c,d,e,f; float x , y , delta; while(cin >> a >> b >> c >> d >> e >> f){ delta = (a * e) - (b * d); x = ((c * e) - (b * f)) / delta; y = ((a * f) - (c * d)) / delta; if(x % 10000 >= 5){ x += 0.001; }if(y % 10000 >=...
a.cc: In function 'int main()': a.cc:16:30: error: invalid operands of types 'float' and 'int' to binary 'operator%' 16 | if(x % 10000 >= 5){ | ~ ^ ~~~~~ | | | | | int | ...
s989070020
p00004
C++
#include <bits/stdc++.h> using namespace std; double a,b,c,d,e,f,y,x; int main (){ while(cin>>a>>b>>c>>d>>e>>f){ y=(((c*d)-(f*a))/((b*d)-(e*a))); x=((ac-(b*y))/a); if(x==0){ x=abs(x); } if(y==0){ y=abs(y); } cout<<fixed<<showpoint<<setprecision(3); cout<<x<<" "<<y<<endl; } }
a.cc: In function 'int main()': a.cc:8:21: error: 'ac' was not declared in this scope; did you mean 'c'? 8 | x=((ac-(b*y))/a); | ^~ | c
s182269976
p00004
C++
import java.util.Scanner; public class V0_0004 { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); while (scanner.hasNextInt()) { int a = scanner.nextInt(); int b = scanner.nextInt(); int c = scanner.nextInt(); int d...
a.cc:1:1: error: 'import' does not name a type 1 | import java.util.Scanner; | ^~~~~~ 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 V0_0004 { | ^~~~~~ a.cc:45:11: error: expected ':' before 'int' 45 | ...
s493870079
p00004
C++
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); while (scanner.hasNextInt()) { int a = scanner.nextInt(); int b = scanner.nextInt(); int c = scanner.nextInt(); int d = ...
a.cc:1:1: error: 'import' does not name a type 1 | import java.util.Scanner; | ^~~~~~ 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 { | ^~~~~~ a.cc:45:11: error: expected ':' before 'int' 45 | p...
s041112532
p00004
C++
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); while (scanner.hasNextInt()) { int a = scanner.nextInt(); int b = scanner.nextInt(); int c = scanner.nextInt(); int d = ...
a.cc:1:1: error: 'import' does not name a type 1 | import java.util.Scanner; | ^~~~~~ 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 { | ^~~~~~ a.cc:45:11: error: expected ':' before 'int' 45 | p...
s719785848
p00004
C++
#include <iostream> #include <cstdio> using namespace std; int main(){ double a=1;, b, c, d, e, f; while(a){ cin >> a >> b>> c>> d>> e>> f; double x, y; x =(c*e-b*f) / (a*e-b*d); y = (c*d-a*f) / (b*d-a*e); printf("%.3f %.3f\n",x, y); } return 0; }
a.cc: In function 'int main()': a.cc:7:12: error: expected primary-expression before ',' token 7 | double a=1;, b, c, d, e, f; | ^ a.cc:7:14: error: 'b' was not declared in this scope 7 | double a=1;, b, c, d, e, f; | ^ a.cc:7:17: error: 'c' was not declared in this scope ...
s072581957
p00004
C++
#include <iostream> #include <iomanip> //#include <fstream> int main(int argc, char **argv){ //std::ifstream ifs("test.txt"); double a = 0; double b = 0; double c = 0; double d = 0; double e = 0; double f = 0; while(std::cin >> a >> b >> c >> d >> e >> f){ //while(ifs >> a >> b >> c >> d >> e >> f){ double...
a.cc: In function 'int main(int, char**)': a.cc:20:26: error: 'round' is not a member of 'std' 20 | x = std::round(x * 1000) / 1000.0; | ^~~~~ a.cc:21:26: error: 'round' is not a member of 'std' 21 | y = std::round(y * 1000) / 1000.0; | ...
s032705234
p00004
C++
#include <iostream> #include <iomanip> #include <sstream> #include <vector> using namespace std; int main() { double a, b, c, d, e, f; vector<string> v; while (cin >> a >> b >> c >> d >> e >> f) { double x, y; x = ((c * e) - (b * f)) / ((a * e) - (b * d)); y = ((c * d) - (a * f)) / ((b * d) - (a * e)); ...
a.cc: In function 'int main()': a.cc:19:21: error: 'round' was not declared in this scope 19 | x = round(x); | ^~~~~
s454206019
p00004
C++
#include<iostream> #include<stdio.h> using namespace std; int main() { double a, b, c, d, e, f, x, y; while (cin >> a >> b >> c >> d >> e >> f;) { double bd = b*d; double ea = e*a; double cd = c*d; double fa = f*a; y = (cd - fa) / (bd - ea); x = (c - b*y) / a; printf("%.3f %.3f\n", x, y); } }
a.cc: In function 'int main()': a.cc:6:49: error: expected ')' before ';' token 6 | while (cin >> a >> b >> c >> d >> e >> f;) { | ~ ^ | ) a.cc:6:50: error: expected primary-expression before ')' token ...
s105106067
p00004
C++
#include<cstdio> #include<iostream> class GCDandLCM{ public: void solve(int a,int b){ int big=a,small=b; if(a<b){ big=b; small=a; int tmp=a; a=b; b=tmp; } while(big%small!=0){ ...
a.cc: In function 'int main()': a.cc:25:11: error: 'cin' was not declared in this scope; did you mean 'std::cin'? 25 | while(cin>>a>>b){ | ^~~ | std::cin In file included from a.cc:2: /usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here 62 | extern istream cin; ...
s396473043
p00004
C++
#include <iostream> using namespace std; int main() { double a[3], b[3]; while (cin >> a[0] >> a[1] >> a[2] >> b[0] >> b[1] >> b[2]) { if (a[0] == 0) { double c = a[2] / a[1]; double d = (b[2] - b[1] * c) / b[1]; a[2] = d; b[2] = d; } else { double c = 1; if (b[0] != 0) { c = a[...
a.cc: In function 'int main()': a.cc:37:34: error: 'setprecision' was not declared in this scope 37 | cout << fixed << setprecision(3) << a[2] << b[2] << endl; | ^~~~~~~~~~~~ a.cc:2:1: note: 'std::setprecision' is defined in header '<iomanip>'; this is probably ...
s855007683
p00004
C++
#include <iostream> using namespace std; int main() { double a[3], b[3]; while (cin >> a[0] >> a[1] >> a[2] >> b[0] >> b[1] >> b[2]) { if (a[0] == 0) { double c = a[2] / a[1]; double d = (b[2] - b[1] * c) / b[1]; a[2] = d; b[2] = d; } else { double c = 1; if (b[0] != 0) { c = a[...
a.cc: In function 'int main()': a.cc:37:34: error: 'setprecision' was not declared in this scope 37 | cout << fixed << setprecision(3) << a[2] << b[2] << endl; | ^~~~~~~~~~~~ a.cc:2:1: note: 'std::setprecision' is defined in header '<iomanip>'; this is probably ...
s746560126
p00004
C++
#include <iostream> #include <iomanip> using namespace std; void OutputSolution(int a, int b, int c, int d, int e, int f) { if(b == 0){ double x = c / a; double y = (f-d*x) / e; }else{ int B = b; a *= e; b *= e; c *= e; d *= B; e *= B; f *= B; double x = (c-f) / (a-d); double y = (c-a*x) / b; ...
a.cc: In function 'void OutputSolution(int, int, int, int, int, int)': a.cc:21:45: error: 'x' was not declared in this scope 21 | cout << fixed << setprecision(3) << x << ' ' << y << endl; | ^ a.cc:21:57: error: 'y' was not declared in this scope 21 | ...
s451244423
p00004
C++
#include <iostream> #include <iomanip> /* ax + by = c dx + ey = f x = (c-by)/a d(c-by)/a + ey = f dc/a - dby/a + ey = f ey - dby/a = f - dc/a y(e-db/a) = f - dc/a y = (f-dc/a)/(e-db/a) aex + bey = ce bdx + bey = bf aex - bdx = ce - bf x(ae - bd) = ce - bf x = (ce - bf)/(ae - bd) by = c - ax y = (c - ax)/b */ int mai...
a.cc: In function 'int main()': a.cc:37:22: error: 'x' was not declared in this scope 37 | std::cout << x << " " << y << std::endl; | ^ a.cc:37:34: error: 'y' was not declared in this scope 37 | std::cout << x << " " << y << std::endl; | ...
s945029719
p00004
C++
#include <iostream> #include <iomanip> using namespace std; void OutputSolution(int a, int b, int c, int d, int e, int f) { long long double x, y; if(b == 0){ x = c / a; y = (f-d*x) / e; }else{ int B = b; a *= e; b *= e; c *= e; d *= B; e *= B; f *= B; x = (c-f) / (a-d); y = (c-a*x) / b; }...
a.cc: In function 'void OutputSolution(int, int, int, int, int, int)': a.cc:7:10: error: 'long long' specified with 'double' 7 | long long double x, y; | ^~~~ a.cc:7:10: error: 'long long' specified with 'double'
s044254489
p00004
C++
#include <iostream> #include <iomanip> using namespace std; int main(??? { int a, b, c, d, e, f; while (cin >> a >> b >> c >> d >> e >> f) { double x = (c*e - b*f) / (a*e - b*d); double y = (c*d - a*f) / (b*d - a*e); printf("%.3f %.3f", x, y); } return 0; }
a.cc:5:5: error: cannot declare '::main' to be a global variable 5 | int main(??? | ^~~~ a.cc:5:10: error: expected primary-expression before '?' token 5 | int main(??? | ^ a.cc:5:11: error: expected primary-expression before '?' token 5 | int main(??? | ^ a.cc:5:12:...
s521672919
p00004
C++
#include <iostream> #include <stdio.h> #define swap(a,b) {a=a+b; b=a-b; a=a-b;} void q4() { double a, b, c, d, e, f; for (;;) { cin >> a >> b >> c >> d >> e >> f; //scanf_s("%lf %lf %lf %lf %lf %lf\n", &a, &b, &c, &d, &e, &f); if (a == 0) { swap(a, d); swap(b, e); swap(c, f); } b /= a; c /= a; ...
a.cc: In function 'void q4()': a.cc:8:17: error: 'cin' was not declared in this scope; did you mean 'std::cin'? 8 | cin >> a >> b >> c >> d >> e >> f; | ^~~ | std::cin In file included from a.cc:1: /usr/include/c++/14/iostream:62:18: note: 'std::cin' decla...
s892342843
p00004
C++
#include <iostream> #include <stdio.h> define swap(a,b) {a=a+b; b=a-b; a=a-b;} using namespace std; void q4() { double a, b, c, d, e, f; for (; cin >> a >> b >> c >> d >> e >> f;) { //cin >> a >> b >> c >> d >> e >> f; //scanf_s("%lf %lf %lf %lf %lf %lf", &a, &b, &c, &d, &e, &f); if (a == 0) { swap(a, d);...
a.cc:3:1: error: 'define' does not name a type 3 | define swap(a,b) {a=a+b; b=a-b; a=a-b;} | ^~~~~~
s084869433
p00004
C++
#include <iostream> #include <iomanip> using namespace std; int main(void){ int a,b,c,d,e,f; double ansX[1000],ansY[1000]; while(std::cin >> a >> b >> c >> d >> e >> f){ ansX = (c*e - b*f) / (a*e - b*d); ansX *= 1000; if(ansX > 0) ansX += 0.5; else ...
a.cc: In function 'int main()': a.cc:9:14: error: incompatible types in assignment of 'int' to 'double [1000]' 9 | ansX = (c*e - b*f) / (a*e - b*d); | ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~ a.cc:10:14: error: invalid operands of types 'double [1000]' and 'int' to binary 'operator*' 10 | a...
s732996998
p00004
C++
#include <iostream> #include<cstdo> using namespace std; int main() { // your code goes here int a,b,c,d,e,f; while(cin >> a >> b >> c >> d >> e >> f ){ double x = (c*e-b*f)/(double)(a*e-b*d); double y = (c*d-a*f)/(double)(b*d-a*e); printf("%.3f %3f\n",x,y); } return 0; }
a.cc:2:9: fatal error: cstdo: No such file or directory 2 | #include<cstdo> | ^~~~~~~ compilation terminated.
s237315839
p00004
C++
#include <iostream> #include<cstdio> using namespace std; ?? int main() { ????????// your code goes here ?? ????double a,b,c,d,e,f; ?? ????while(cin >> a >> b >> c >> d >> e >> f ){ ?? ????????double x = (c*e-b*f)/(a*e-b*d); ????????double y = (c-a*x)/b; ????????if(x == -0.0){ ????????????x = 0.0; ????????} ????????if(...
a.cc:6:7: warning: trigraph ??/ ignored, use -trigraphs to enable [-Wtrigraphs] 6 | ????????// your code goes here a.cc:4:1: error: expected unqualified-id before '?' token 4 | ?? | ^
s746211109
p00004
C++
#include <bits/stdc++.h> using namespace std; #define Vi vector<int> #define FOR(i,s,e) for (int i=s; i<e; i++) #define ITER(v) v.begin(), v.end() int main() { cin.tie(0); ios::sync_with_stdio(false); int a, b, c, d, e, f; double den, x, y; while (true) { cin >> a >> b >> c >> d >> e >>...
a.cc: In function 'int main()': a.cc:23:17: error: expected ';' before 'y' 23 | x += 0.0 | ^ | ; 24 | y += 0.0 | ~
s742610033
p00004
C++
int main(){ double a,b,c,d,e,f,x,y; while(scanf("%lf%lf%lf%lf%lf%lf",&a,&b,&c,&d,&e,&f)!=EOF){ y=(((c*d)-(a*f))/((b*d)-(a*e))); x=(((c*e)-(b*f))/((a*e)-(b*d))); printf("%3lf %3lf\n",x,y); } return 0; }
a.cc: In function 'int main()': a.cc:3:15: error: 'scanf' was not declared in this scope 3 | while(scanf("%lf%lf%lf%lf%lf%lf",&a,&b,&c,&d,&e,&f)!=EOF){ | ^~~~~ a.cc:3:62: error: 'EOF' was not declared in this scope 3 | while(scanf("%lf%lf%lf%lf%lf%lf",&a,&b,&c,&d,&e,&f)!=EOF)...
s365677640
p00004
C++
int main() { double a, b, c, d, e, f, x, y; while(scanf("%lf%lf%lf%lf%lf%lf", &a, &b, &c, &d, &e, &f) != EOF) { x = (b*f - c*e) / (b*d - a*e); y = (c*d - a*f) / (b*d - a*e); if(abs(x) < 0.000001 && x < 0) x = 0.0; if(abs(y) < 0.000001 && y < 0) y = 0.0; printf("%.3f %.3f\n", x, y...
a.cc: In function 'int main()': a.cc:4:9: error: 'scanf' was not declared in this scope 4 | while(scanf("%lf%lf%lf%lf%lf%lf", &a, &b, &c, &d, &e, &f) != EOF) | ^~~~~ a.cc:4:64: error: 'EOF' was not declared in this scope 4 | while(scanf("%lf%lf%lf%lf%lf%lf", &a, &b, &c, &d, &e, &f) != EOF) ...
s037516423
p00004
C++
using namespace std; #define j bai; int main() { double a, b, c, d, e, y, x, f, bai; bool bo = false; while (cin >> a >> b >> c >> d >> e >> f) { if (a ==0 || b ==0) { if (a) { y = c / b; x = f / d - e*y; } else if (b) { x = a / c; y = f / e - d*x; } bo = true; } else if (d == 0...
a.cc: In function 'int main()': a.cc:7:16: error: 'cin' was not declared in this scope 7 | while (cin >> a >> b >> c >> d >> e >> f) { | ^~~ a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>' +++ |+#include <iostream>...
s145252096
p00004
C++
// // main.cpp // Sample // // Created by h3037183 on 2017/07/31. // Copyright ?? 2017??´ ?°????. All rights reserved. // #include <iostream> #include<cstdio> #include<algorithm> using namespace std; int main(){ double a,b,c,d,e,f,x,y; for(;;){ cin>>a>>b>>c>>d>>e>>f; x=(c*e-b*f)/(a*e-b*d); y=(c...
a.cc: In function 'int main()': a.cc:22:5: error: break statement not within loop or switch 22 | break | ^~~~~ a.cc:22:10: error: expected ';' before 'return' 22 | break | ^ | ; 23 | return 0; | ~~~~~~
s748724509
p00004
C++
#include <iostream> #include<cstdio> using namespace std; int main() { // your code goes here double a,b,c,d,e,f; while(cin >> a >> b >> c >> d >> e >> f ){ double x = (double)((e*c-b*f) / (a*e-b*d)); ????double y = (double)((-(d*c)+a*f) / (a*e-b*d)); if(y == 0){ y = 0; } if(x == 0){ x =...
a.cc: In function 'int main()': a.cc:13:1: error: expected primary-expression before '?' token 13 | ????double y = (double)((-(d*c)+a*f) / (a*e-b*d)); | ^ a.cc:13:2: error: expected primary-expression before '?' token 13 | ????double y = (double)((-(d*c)+a*f) / (a*e-b*d)); | ^ a.cc:13:3: error: expec...
s835589161
p00004
C++
#include <iostream> #include<cstdio> using namespace std; int main() { // your code goes here double a,b,c,d,e,f; double x,y while(cin >> a >> b >> c >> d >> e >> f ){ x =(double)((e*c-b*f)/(a*e-b*d)); y = (double)((-(d*c)+a*f)/(a*e-b*d)); if(y == 0){ y = 0; } if(x == 0){ x ...
a.cc: In function 'int main()': a.cc:11:3: error: expected initializer before 'while' 11 | while(cin >> a >> b >> c >> d >> e >> f ){ | ^~~~~
s748790755
p00004
C++
#include<stdio.h> int main(){ double a,b,c,d,e,f,x,y,; while(scanf("%lf%lf%lf%lf%lf%lf",&a,&b,&c,&d,&e,&f)){ x=((c*e-f*b)/(a*e-d*b)); y=((c-a*x)/b); if(x>0)x+=0.0005; else x-=0.0005; if(y>0)x+=0.0005; else y=-=0.0005; printf("%.3ld %.3ld",x,y); } return 0; }
a.cc: In function 'int main()': a.cc:3:32: error: expected unqualified-id before ';' token 3 | double a,b,c,d,e,f,x,y,; | ^ a.cc:10:24: error: expected primary-expression before '-=' token 10 | else y=-=0.0005; | ^~
s994346572
p00004
C++
#include<stdio.h> int main(){ double a,b,c,d,e,f; while(scanf("%lf%lf%lf%lf%lf%lf",&a,&b,&c,&d,&e,&f)!=-1){ printf("%.3lf %.3lf\n",(c*e-f*b)==0?0:(c*e-f*b)/(a*e-d*b),(c*d-a*f)==0?0:(cd-a*f)/(bd-ae)); } return 0; }
a.cc: In function 'int main()': a.cc:5:91: error: 'cd' was not declared in this scope; did you mean 'd'? 5 | printf("%.3lf %.3lf\n",(c*e-f*b)==0?0:(c*e-f*b)/(a*e-d*b),(c*d-a*f)==0?0:(cd-a*f)/(bd-ae)); | ^...
s265549953
p00004
C++
#include<stdio.h> int main(){ double a,b,c,d,e,f; double x,y,z,v; while(scanf("%lf %lf %lf %lf %lf %lf",&a,&b,&c,&d,&e,&f)!=-1) x=(c*e-b*f)/(a*e-b*d); y=(c*d-a*f)/(b*d-a*e); if(x>=-0.0005&&x<0.0005) x=0; if(y>=-0.0005&&y<0.0005) y=0; printf("%.3lf %.3lf\n",x,y); } }
a.cc:12:1: error: expected declaration before '}' token 12 | } | ^
s593178893
p00004
C++
#include <iostream> #include <iomanip> using namespace std; constexpr double eps = 1e-8; int main() { double a, b, c, d, e, f, x, y; while (cin >> a >> b >> c >> d >> e >> f) { x = (c * e - b * f) / (a * e - b * d); y = (c - a * x) / b; if (fabs(x) < eps) x = 0; if (fabs(y) < eps) y = 0; cout <...
a.cc: In function 'int main()': a.cc:11:9: error: 'fabs' was not declared in this scope; did you mean 'labs'? 11 | if (fabs(x) < eps) x = 0; | ^~~~ | labs a.cc:12:9: error: 'fabs' was not declared in this scope; did you mean 'labs'? 12 | if (fabs(y) < eps) y = 0; | ...
s293328902
p00004
C++
#include<iostream> using namespace std; void main(){ int a,b,c,d,e,f; cout<<"ax+by=c"<<endl<<"dx+ef=f"<<endl; cout<<" ????§£???x,y??????????????????"<<endl; cout<<"a b c d e f >>>>"; cin>>a>>b>>c>>d>>e>>f; cout<<"x="<<(e*c-b*f)/(a*e-b*d) <<"y="<<(-c*d+a*f)/(a*e-b*d)<<endl; }
a.cc:4:1: error: '::main' must return 'int' 4 | void main(){ | ^~~~
s107184409
p00004
C++
#include<iostream> #include<iomanip> double shisyagonyu(double x if(x>0){ x += 0.0005; } if(x<0){ x -= 0.0005; } return x; } int main(){ double a,b,c,d,e,f,x,y; while(std::cin >>a>>b>>c>>d>>e>>f){ /*x = (c*e-b*f)/(a*e-b*d); y = (a*f-c*d)/(a*e-b*d); std::cout << x; std::cout <<...
a.cc:5:3: error: expected ',' or '...' before 'if' 5 | if(x>0){ | ^~ a.cc:11:11: error: expected ')' before ';' token 11 | return x; | ^ | ) a.cc:4:19: note: to match this '(' 4 | double shisyagonyu(double x | ^ a.cc:12:1: error: expected de...