submission_id
stringlengths
10
10
problem_id
stringlengths
6
6
language
stringclasses
3 values
code
stringlengths
1
522k
compiler_output
stringlengths
43
10.2k
s359028523
p00007
C++
#include <iostream> using namespace std; int main () { int n, i; double a = 100000; cin >> n; for(i=0;i<n;i++) { a *= 1.05; while(a%1000!=0) { a += 1; } } cout << a << endl; }
a.cc: In function 'int main()': a.cc:10:16: error: invalid operands of types 'double' and 'int' to binary 'operator%' 10 | while(a%1000!=0) { | ~^~~~~ | | | | | int | double
s444672656
p00007
C++
#include <iostream> #include <algorithm> int main() { const int BASE = 100000; int n, debt = BASE; std::cin >> n; while (n--) { debt = (loan * 1.05 + 999) / 1000; debt *= 1000; } std::cout << debt << std::endl; return 0; }
a.cc: In function 'int main()': a.cc:9:13: error: 'loan' was not declared in this scope 9 | debt = (loan * 1.05 + 999) / 1000; | ^~~~
s473168891
p00007
C++
#include <iostream> using namespace std; int main() { unsigned long long debt = 100000; int n; for (int i = 0; i < n; ++i) { debt *= 1.05; const int under debt -= (debt % 2000) - 2000; } cout << debt << endl; return 0; }
a.cc: In function 'int main()': a.cc:13:9: error: expected initializer before 'debt' 13 | debt -= (debt % 2000) - 2000; | ^~~~
s081454732
p00007
C++
#include <cstdio> using namespace std; in main() { int n = 0; double N = 0; int M = 100; int L = 100; scanf("%d", &n); for (int i = 0; i < n; i++) { N = L; N = M; N *= 1.05; N -= M; L += N; while (N> 1){ N -= 1; } if (N > 0) { L += 1; } } L *= 1000; printf("%d", L); return 0; }
a.cc:5:1: error: 'in' does not name a type; did you mean 'int'? 5 | in main() { | ^~ | int
s343726746
p00007
C++
import java.math.BigDecimal; class Main { public void main(int week) { BigDecimal shakkin = new BigDecimal(100000); BigDecimal taxper = new BigDecimal(0.05); BigDecimal rishi; int a = 0; for (int i = 0; i <= week; i++) { // 5%の利子を計算する rishi = shakkin.multiply(taxper); // 5%の利子を元金に足す shakkin = sh...
a.cc:1:1: error: 'import' does not name a type 1 | import java.math.BigDecimal; | ^~~~~~ a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts' a.cc:3:7: error: expected ':' before 'void' 3 | public void main(int week) { | ^~~~~ | : a.cc:20:2: error: expected ';' after c...
s750479235
p00007
C++
import java.math.BigDecimal; import java.util.Scanner; class Main { public static final int DEPT = 100000; public static final BigDecimal INTEREST = new BigDecimal(0.05); public static void main(String[] args) { Scanner s = new Scanner(System.in); int week = Integer.parseInt(s.next()); ...
a.cc:1:1: error: 'import' does not name a type 1 | import java.math.BigDecimal; | ^~~~~~ a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts' 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 '-fmodul...
s418121578
p00007
C++
#include <iostream> using namespace std; int main() { // your code goes here int n,ans; ans = 100000 cin >> n; for (int i=0;i<n;i++) { ans = ans * 1.05; if (ans%1000!=0)ans=ans + ans%1000 } cout << ans; return 0; }
a.cc: In function 'int main()': a.cc:7:21: error: expected ';' before 'cin' 7 | ans = 100000 | ^ | ; 8 | cin >> n; | ~~~ a.cc:11:51: error: expected ';' before '}' token 11 | if (ans%1000!=0)ans=ans + ...
s356440017
p00007
C++
#include <iostream> using namespace std; int main() { // your code goes here int n,ans; ans = 100000; cin >> n; for (int i=0;i<n;i++) { ans = ans * 1.05; if (ans%1000!=0)ans=ans + ans%1000 } cout << ans; return 0; }
a.cc: In function 'int main()': a.cc:11:51: error: expected ';' before '}' token 11 | if (ans%1000!=0)ans=ans + ans%1000 | ^ | ; 12 | } | ~ ...
s291338759
p00007
C++
#include <iostream> using namespace std; ?? int main() { ????????????int n = 100000; ????????????cin >> n; ????????????for (int i=0;i<n;i++) { ????????????????????????n = 1.05*n; ????????????????????????if (n%1000!=0) { ????????????????????????????????????n = n + (1000-n%1000); ????????????????????????} ????????????} ?...
a.cc:3:1: error: expected unqualified-id before '?' token 3 | ?? | ^
s285024923
p00007
C++
#include <iostream> using namespace std; ?? int main() { ????????????int n,x; x = 100000; ????????????cin >> n; ????????????for (int i=0;i<n;i++) { ????????????????????????x = 1.05*x; ????????????????????????if (x%1000!=0) { ????????????????????????????????????x = x + (1000-x%1000); ????????????????????????} ????...
a.cc:3:1: error: expected unqualified-id before '?' token 3 | ?? | ^
s548889735
p00007
C++
13530000
a.cc:1:1: error: expected unqualified-id before numeric constant 1 | 13530000 | ^~~~~~~~
s933064098
p00007
C++
#include <iostream> int main(){ int n; while(std::cin >> n){ double result=100; while(n--){ result*=1.05; if(result%1000!=0)result+=1000-result%1000; } result*=1000; std::cou...
a.cc: In function 'int main()': a.cc:9:34: error: invalid operands of types 'double' and 'int' to binary 'operator%' 9 | if(result%1000!=0)result+=1000-result%1000; | ~~~~~~^~~~~ | | | | d...
s640023956
p00007
C++
int main(void) { int i, n, k; scanf("%d",&n); i = 100000; while (n > 0) { i = i * 1.05; if(!(i % 1000 == 0)) { k = i % 1000; i = i + 1000 - k; } n--; } printf("%d\n", i); return 0; }
a.cc: In function 'int main()': a.cc:3:5: error: 'scanf' was not declared in this scope 3 | scanf("%d",&n); | ^~~~~ a.cc:14:5: error: 'printf' was not declared in this scope 14 | printf("%d\n", i); | ^~~~~~ a.cc:1:1: note: 'printf' is defined in header '<cstdio>'; this is probably fix...
s198369775
p00007
C++
a=1e5;main(N){scanf("%d",&N);while(N--)a*=1.05,a+=(a%1000)?1e3-a%1000:0;a=!printf("%d\n",a);}
a.cc:1:1: error: 'a' does not name a type 1 | a=1e5;main(N){scanf("%d",&N);while(N--)a*=1.05,a+=(a%1000)?1e3-a%1000:0;a=!printf("%d\n",a);} | ^ a.cc:1:11: error: expected constructor, destructor, or type conversion before '(' token 1 | a=1e5;main(N){scanf("%d",&N);while(N--)a*=1.05,a+=(a%1000)?1e3-a%1000:...
s848787237
p00007
C++
#include<iostream> int main(){ int n,a,i std::cin>>n; for(a=100000,i=0;i<n;++i){ a=a+a/20; if(a%1000=0){ a=a+1000-a%1000 } ++a } std::cout<<a<<std::endl; } return 0;
a.cc: In function 'int main()': a.cc:5:1: error: expected initializer before 'std' 5 | std::cin>>n; | ^~~ a.cc:6:15: error: 'i' was not declared in this scope 6 | for(a=100000,i=0;i<n;++i){ | ^ a.cc:8:13: error: lvalue required as left operand of assignment 8 | if(a%1000=0...
s768021925
p00007
C++
main = do n <- readLn :: IO Int let debt x = 100 * ceiling $ x * 0.0105 print $ iterate n debt x !! n
a.cc:1:1: error: 'main' does not name a type 1 | main = do | ^~~~
s169893416
p00007
C++
#include <iostream> #include<math.h> using namespace std; int main(void){ unsigned long int n, sum = 100000; long double Ceil; cin >> n; for (int i = 0; i < n; i++){ sum /= 1000; Ceil = ceil(sum*1.05); sum=Ceil*1000; } cout << unsigned long int(sum) << endl; return 0; }
a.cc: In function 'int main()': a.cc:20:17: error: expected primary-expression before 'unsigned' 20 | cout << unsigned long int(sum) << endl; | ^~~~~~~~
s380034049
p00007
C++
#include <iostream> using namespace std; int main() { int n; cin >> n; int ans = 100000; int tmp; for (int i=0; i<n; i++) { ans *= 1.05; tmp = ans / 1000 * 1000; if (tmp != ans) ans = tmp + 1000; } cout << ans << endl; return 0;
a.cc: In function 'int main()': a.cc:15:18: error: expected '}' at end of input 15 | return 0; | ^ a.cc:5:12: note: to match this '{' 5 | int main() { | ^
s224758280
p00007
C++
a=100000 gets.to_i.times{a=a*105/100;a=(a/1000+1)*1000 if a%1000!=0;} puts a
a.cc:1:1: error: 'a' does not name a type 1 | a=100000 | ^ a.cc:3:1: error: 'puts' does not name a type 3 | puts a | ^~~~
s726738612
p00007
C++
a=100000;gets.to_i.times{a=a*105/100;a=(a/1000+1)*1000 if a%1000!=0;};puts a
a.cc:1:1: error: 'a' does not name a type 1 | a=100000;gets.to_i.times{a=a*105/100;a=(a/1000+1)*1000 if a%1000!=0;};puts a | ^ a.cc:1:10: error: 'gets' does not name a type 1 | a=100000;gets.to_i.times{a=a*105/100;a=(a/1000+1)*1000 if a%1000!=0;};puts a | ^~~~ a.cc:1:71: error: 'puts' does ...
s082498404
p00007
C++
a=100000;gets.to_i.times{a=((a*1.05/1000).ceil)*1000;};puts a;
a.cc:1:1: error: 'a' does not name a type 1 | a=100000;gets.to_i.times{a=((a*1.05/1000).ceil)*1000;};puts a; | ^ a.cc:1:10: error: 'gets' does not name a type 1 | a=100000;gets.to_i.times{a=((a*1.05/1000).ceil)*1000;};puts a; | ^~~~ a.cc:1:56: error: 'puts' does not name a type 1 | a=10...
s612527153
p00007
C++
#include<iostream> #include<string> using namespace std; int main(){ double a=100000; int n; cin>>n; for(int i=0;i<n;i++){ a*=1.05; if(a%1000==0) a-=1000; a/=1000; a*=1000; a+=1000; } cout<<a<<endl; return 0; }
a.cc: In function 'int main()': a.cc:10:21: error: invalid operands of types 'double' and 'int' to binary 'operator%' 10 | if(a%1000==0) | ~^~~~~ | | | | | int | double
s217748972
p00007
C++
#include <iostream> using namespace std; int main() { int n; while (cin >> n) { while (n--) { money *= 1.05; } if (money % 10000 != 0) { money -= (money % 10000); money += 10000; } cout << money << endl; } return 0; }
a.cc: In function 'int main()': a.cc:11:25: error: 'money' was not declared in this scope 11 | money *= 1.05; | ^~~~~ a.cc:13:21: error: 'money' was not declared in this scope 13 | if (money % 10000 != 0) | ^~~~~ a.cc:...
s549004212
p00007
C++
#include <iostream> using namespace std; int main() { double monthlyPayment; double balance; double interestRate; int month = 1; cout.setf(ios::fixed); // These lines force currency format in output to 2 decimal pts cout.setf(ios::showpoint); cout.precision(2); cout << "Enter the current balance of your loan...
a.cc: In function 'int main()': a.cc:45:18: error: expected '}' at end of input 45 | return 0; | ^ a.cc:5:1: note: to match this '{' 5 | { | ^
s215723517
p00007
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:64:14: error: 'long long' specified with 'double' 64 | long long double money = 100000; | ^~~~
s204845469
p00007
C++
#include<iostream> #include<math.h> #include<stdio.h> #include<windows.h> using namespace std; int main() { int n; double dbt; dbt = 100000; cin >> n; for (; n > 0; n--) { dbt = dbt * 1.05; dbt = dbt / 1000; dbt = ceil(dbt); dbt = dbt * 1000; } cout << dbt << ...
a.cc:4:9: fatal error: windows.h: No such file or directory 4 | #include<windows.h> | ^~~~~~~~~~~ compilation terminated.
s731029299
p00007
C++
#include<stdio.h> int main(void) { int n float p scanf("%d",&n); p=1.05; for(i=0;i<n;i++){ w=100000*p; if(1000%w>0){ w=w-(1000%w)+1000; }
a.cc: In function 'int main()': a.cc:5:9: error: expected initializer before 'float' 5 | float p | ^~~~~ a.cc:7:9: error: 'p' was not declared in this scope 7 | p=1.05; | ^ a.cc:8:13: error: 'i' was not declared in this scope 8 | for(i=0;i<n;i++){ | ...
s922083269
p00007
C++
#include<iostream> #include<algorithm> #include<cstring> using namespace std; int main(){ int >> n; cin >> n; price = 100000; for(int i = 0; i < n; i++){ price *= 1.05; } if(price % 1000 !== 0) price = price -(price % 1000) + 1000; cout << price << endl; }
a.cc: In function 'int main()': a.cc:7:7: error: expected unqualified-id before '>>' token 7 | int >> n; | ^~ a.cc:8:10: error: 'n' was not declared in this scope 8 | cin >> n; | ^ a.cc:9:3: error: 'price' was not declared in this scope 9 | price = 100000; | ^~~~~ a....
s284882690
p00007
C++
#include <iostream> #include <math.h> using namespace std; void test(); int interest(int debt, float interest_rate, int n); int main(void) { test(); return 0; } void test() { int debt,n; double money; float interest_rate; debt = 100000; interest_rate = 1.05; cin >> n; debt = interest(debt, interest_rate,...
a.cc:28:53: warning: trigraph ??/ ignored, use -trigraphs to enable [-Wtrigraphs] 28 | money = ceil(money) * 10000;??????????????????// ?°???°?????\????????????????????????????????? a.cc:35:54: warning: trigraph ??/ ignored, use -trigraphs to enable [-Wtrigraphs] 35 | int interest(int debt, float interest...
s375783056
p00007
C++
#include <iostream> #include <math.h> using namespace std; void test(); int interest(int debt, float interest_rate, int n); int main(void) { test(); return 0; } void test() { int debt,n; double money; float interest_rate; debt = 100000; interest_rate = 1.05; cin >> n; debt = interest(debt, interest_rate,...
a.cc:28:52: warning: trigraph ??/ ignored, use -trigraphs to enable [-Wtrigraphs] 28 | money = ceil(money) * 1000;??????????????????// ?°???°?????\????????????????????????????????? a.cc:35:54: warning: trigraph ??/ ignored, use -trigraphs to enable [-Wtrigraphs] 35 | int interest(int debt, float interest_...
s242685595
p00007
C++
#include <iostream> #include <math.h> using namespace std; void test(); int interest(int debt, float interest_rate, int n); int main(void) { test(); return 0; } void test() { int debt,n; double money; float interest_rate; debt = 100000; interest_rate = 1.05; cin >> n; debt = interest(debt, interest_rate,...
a.cc:35:54: warning: trigraph ??/ ignored, use -trigraphs to enable [-Wtrigraphs] 35 | int interest(int debt, float interest_rate,int n)??????//?????°??¢??° a.cc:35:50: error: expected initializer before '?' token 35 | int interest(int debt, float interest_rate,int n)??????//?????°??¢??° | ...
s694992269
p00007
C++
#include <iostream> #include <math.h> using namespace std; void test3()??? int interest(int debt, double interest_rate,int n); int main(void) { test(); return 0; } void test() { int debt,n; debt = 100000; cin >> n; debt = interest(debt, 1.05, n) ; if (debt % 1000 > 0) { debt = debt - (int)debt % 1000 + ...
a.cc:5:13: error: expected initializer before '?' token 5 | void test3()??? | ^ a.cc: In function 'int main()': a.cc:11:9: error: 'test' was not declared in this scope 11 | test(); | ^~~~ a.cc: In function 'void test()': a.cc:21:16: error: 'interest' was not declared in th...
s916595602
p00007
C++
#include <iostream> #include <string> #include <vector> #include <algorithm> #include <set> #include <map> //ranker using namespace std; using ll = long long; using lli = ll int; using ull = unsigned long long; using vi = vector<int>; using vvi = vector<vi>; using vvvi = vector<vvi>; using pii = pair<int, int>; using ...
a.cc:11:13: error: two or more data types in declaration of 'type name' 11 | using lli = ll int; | ^~ a.cc: In function 'int main()': a.cc:26:7: error: redeclaration of 'int sum' 26 | int sum, tot, ans, num; | ^~~ a.cc:24:10: note: 'int sum' previously declared here 24 | int n...
s508174337
p00007
C++
#include <iostream> #include <string> #include <vector> #include <algorithm> #include <set> #include <map> //ranker using namespace std; using ll = long long; using lli = ll int; using ull = unsigned long long; using vi = vector<int>; using vvi = vector<vi>; using vvvi = vector<vvi>; using pii = pair<int, int>; using ...
a.cc:11:13: error: two or more data types in declaration of 'type name' 11 | using lli = ll int; | ^~ a.cc: In function 'int main()': a.cc:33:22: error: expected ';' before 'return' 33 | cout << sum << endl | ^ | ; 34 | return 0; ...
s173288269
p00007
C++
#include <iostream> #include <string> #include <vector> #include <algorithm> #include <set> #include <map> //ranker using namespace std; using ll = long long; using lli = ll int; using ull = unsigned long long; using vi = vector<int>; using vvi = vector<vi>; using vvvi = vector<vvi>; using pii = pair<int, int>; using ...
a.cc:11:13: error: two or more data types in declaration of 'type name' 11 | using lli = ll int; | ^~
s831456283
p00007
C++
#include <iostream> #include <string> #include <vector> #include <algorithm> #include <set> #include <map> #include <cmath> //ranker using namespace std; #define REPS(i, a, n) for (int i = (a); i < (n); ++i) #define REP(i, n) REPS(i, 0, n) #define RREP(i, n) REPS(i, 1, n + 1) #define DEPS(i, a, n) for (int i = (a); i ...
a.cc: In function 'int main()': a.cc:32:4: error: no match for 'operator<<' (operand types are 'std::istream' {aka 'std::basic_istream<char>'} and 'int') 32 | cin<<n; | ~~~^~~ | | | | | int | std::istream {aka std::basic_istream<char>} a.cc:32:4: note: candidate: 'operator<<(int, int)' ...
s458169330
p00007
C++
#include <iostream> int main(){ int n; int debt = 100000; std::cin >> n; for(int i=0; i<n; i++){ debt = round((double)debt * 1.05); int under = debt % 1000; if(under==0) else{ debt = debt - under + 1000; } } std::cout << debt << std::endl; return 0; }
a.cc: In function 'int main()': a.cc:9:12: error: 'round' was not declared in this scope 9 | debt = round((double)debt * 1.05); | ^~~~~ a.cc:12:5: error: expected primary-expression before 'else' 12 | else{ | ^~~~
s694420653
p00007
C++
#include <iostream> int main(){ int n; int debt = 100000; std::cin >> n; for(int i=0; i<n; i++){ debt = round((double)debt * 1.05); int under = debt % 1000; if(under==0) else{ debt = debt - under + 1000; } } std::cout << debt << std::endl; return 0; }
a.cc: In function 'int main()': a.cc:9:12: error: 'round' was not declared in this scope 9 | debt = round((double)debt * 1.05); | ^~~~~ a.cc:12:5: error: expected primary-expression before 'else' 12 | else{ | ^~~~
s204282513
p00007
C++
#include <iostream> #include <math.h> int main(){ int n; int debt = 100000; std::cin >> n; for(int i=0; i<n; i++){ debt = round((double)debt * 1.05); int under = debt % 1000; if(under==0) else{ debt = debt - under + 1000; } } std::cout << debt << std::endl; return 0; }
a.cc: In function 'int main()': a.cc:13:5: error: expected primary-expression before 'else' 13 | else{ | ^~~~
s174911328
p00007
C++
#include<iostream> //#include<algorithm> //#include<cmath> //#include<string> //#include<cctype> //#include <vector> using namespace std; int main(){ int a=100,n; cin >> n; while (n--) a = ceil(a*1.05); cout << a * 1000 << endl; return 0; }
a.cc: In function 'int main()': a.cc:11:25: error: 'ceil' was not declared in this scope 11 | while (n--) a = ceil(a*1.05); | ^~~~
s182758233
p00007
C++
import sys import math as m n=int(input()) out=100000 for i in range(n): out=m.ceil(out*1.05/1000)*1000 print(out) #for i in sys.stdin: # a,b=map(int,i.split()) # print(gcd(a,b),lcm(a,b))
a.cc:9:2: error: invalid preprocessing directive #for 9 | #for i in sys.stdin: | ^~~ a.cc:10:9: error: invalid preprocessing directive #a 10 | # a,b=map(int,i.split()) | ^ a.cc:11:9: error: invalid preprocessing directive #print 11 | # print(gcd(a,b),lcm(a,b)) | ...
s544009374
p00007
C++
#include <algorithm> #include <cassert> #include <cctype> #include <climits> #include <cmath> #include <complex> #include <cstdio> #include <cstdlib> #include <cstring> #include <ctime> #include <iostream> #include <iterator> #include <list> #include <map> #include <numeric> #include <queue> #include <set> #include ...
a.cc: In function 'int main()': a.cc:35:15: error: invalid operands of types 'long double' and 'int' to binary 'operator%' 35 | if (a % 1000 == 0) { | ~ ^ ~~~~ | | | | | int | long double a.cc:38:27: error: invalid operands of types ...
s844829948
p00007
C++
#include <iostream> using namespace std; int main() { int n; double money=100; cin >> n; for (size_t i = 0; i < n; i++) { money = money*1.05; money = ceil(money); } cout << money * 1000 << endl; return 0; }
a.cc: In function 'int main()': a.cc:13:25: error: 'ceil' was not declared in this scope 13 | money = ceil(money); | ^~~~
s727322589
p00007
C++
#include<iostream> int week(int money){ money = money + money * 0.05; money = money + 1000 - ( money % 1000 ); return money; } int main(void){ int n; int money = 100000; cin >> n; for(int i = 0;i < n;i++){ money = week(money); } return 0; }
a.cc: In function 'int main()': a.cc:12:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'? 12 | cin >> n; | ^~~ | std::cin In file included from a.cc:1: /usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here 62 | extern istream cin; ...
s659160446
p00007
C++
#include<iostream> using namedspace std; int week(int money){ money = money + money * 0.05; money = money + 1000 - ( money % 1000 ); return money; } int main(void){ int n; int money = 100000; cin >> n; for(int i = 0;i < n;i++){ money = week(money); } return 0; }
a.cc:3:7: error: expected nested-name-specifier before 'namedspace' 3 | using namedspace std; | ^~~~~~~~~~ a.cc: In function 'int main()': a.cc:14:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'? 14 | cin >> n; | ^~~ | std::cin In file inclu...
s281051942
p00007
C++
#include<iostream> using namedspace std; int week(int money){ money = money + money * 0.05; money = money + 1000 - ( money % 1000 ); return money; } int main(void){ int n; int money = 100000; cin >> n; for(int i = 0;i < n;i++){ money = week(money); } cout << money << endl; return 0; }
a.cc:3:7: error: expected nested-name-specifier before 'namedspace' 3 | using namedspace std; | ^~~~~~~~~~ a.cc: In function 'int main()': a.cc:14:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'? 14 | cin >> n; | ^~~ | std::cin In file inclu...
s236923298
p00007
C++
#include <iostream> int main(){ long long int Debt = 100000; int n; cin >> n; for (int i=0; i<n; i++) Debt = Debt * 1.05; if(Debt % 10000 > 0) Debt = Debt + 10000; return 0; }
a.cc: In function 'int main()': a.cc:7:2: error: 'cin' was not declared in this scope; did you mean 'std::cin'? 7 | cin >> n; | ^~~ | std::cin In file included from a.cc:1: /usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here 62 | extern istream cin; ///< Linked to standa...
s022296039
p00007
C++
#include<stdio.h> #include<iostream> using#include<stdio.h> #include<iostream> using namespace std; int main(){ int n=0; int m=100000; cin>>n; for(int i=0;i<n;i++){ m=m*1.05; if(m%1000!=0){ m=m+1000; } } cout<<m<<endl; return 0; }
a.cc:3:6: error: stray '#' in program 3 | using#include<stdio.h> | ^ a.cc:3:7: error: expected nested-name-specifier before 'include' 3 | using#include<stdio.h> | ^~~~~~~ a.cc: In function 'int main()': a.cc:9:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'? 9 ...
s350711729
p00007
C++
include <iostream> # include <stdio.h> # include <math.h> using namespace std; int main() { int n; cin>>n; float newamount=100000; for(int i=0;i<n;i++){ float copy=newamount*21/20; copy=ceil(copy/1000); copy=copy*1000; newamount=copy; } cout<<ceil(newamount); return 0; }
a.cc:1:1: error: 'include' does not name a type 1 | include <iostream> | ^~~~~~~ In file included from /usr/include/math.h:275, from /usr/include/c++/14/cmath:47, from /usr/include/c++/14/math.h:36, from a.cc:3: /usr/include/x86_64-linux-gnu/bits/mathcalls.h:...
s695201944
p00007
C++
#include <stdio.h> int main(void) { int a,c,i; int b; scanf_s("%d", &a); b = 100000; for (i = 0; i < a; i++) { b = b * 1.05; } c = b % 10000; if (c!=0) { b = b + 10000-c; } printf("%d", b); return 0; }
a.cc: In function 'int main()': a.cc:5:9: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'? 5 | scanf_s("%d", &a); | ^~~~~~~ | scanf
s082443790
p00007
C++
#include<iostream> using namespace std; int main(){ int n; int money = 100000; for(int i = 0; i < n; ++i){ maney = money + (money * 0.05); if(money % 1000 != 0){ money += 1000; } } cout << money << endl; return 0; }
a.cc: In function 'int main()': a.cc:9:3: error: 'maney' was not declared in this scope; did you mean 'money'? 9 | maney = money + (money * 0.05); | ^~~~~ | money
s107460200
p00007
C++
#include <iostream> #include <vector> #include <math.h> #include <string> #include <windows.h> int main(void); int kiriage(int num); int main(){ int n; //n週 int debut = 100000; //借金 std::cin >> n; for (int i = 0; i < n; i++) { debut *= 1.05; std::string str_debut = std::to_string(debut); if ((str_de...
a.cc:5:10: fatal error: windows.h: No such file or directory 5 | #include <windows.h> | ^~~~~~~~~~~ compilation terminated.
s683159205
p00007
C++
#include <iostream> #include <vector> #include <math.h> #include <string> #include <windows.h> int main(void); int kiriage(int num); int main(){ int n; //n週 int debut = 100000; //借金 std::cin >> n; for (int i = 0; i < n; i++) { debut *= 1.05; std::string str_debut = std::to_string(debut); if ((str_de...
a.cc:5:10: fatal error: windows.h: No such file or directory 5 | #include <windows.h> | ^~~~~~~~~~~ compilation terminated.
s262109163
p00007
C++
#include <iostream> using namespace std; int main(){ int n; cin>>n; int temp = 0,k; for(int i = 0; i < n; i++){ k = (int)(sum * 0.05) % 1000; if(k != 0) temp = 1000; else temp = 0; sum += sum * 0.05 + temp - k; } cout<<sum<<endl; retur...
a.cc: In function 'int main()': a.cc:9:19: error: 'sum' was not declared in this scope 9 | k = (int)(sum * 0.05) % 1000; | ^~~ a.cc:16:11: error: 'sum' was not declared in this scope 16 | cout<<sum<<endl; | ^~~
s493865039
p00007
C++
#include<iostream> using namespace std; int main() { int d = 100000; int n; cin >> n; while(n > 0; n--) { d *= 1.05; if(d % 1000) { d = (d / 1000 + 1) * 1000; } } cout << d << endl; return 0; }
a.cc: In function 'int main()': a.cc:8:16: error: expected ')' before ';' token 8 | while(n > 0; n--) { | ~ ^ | ) a.cc:8:21: error: expected ';' before ')' token 8 | while(n > 0; n--) { | ^ | ;
s868381950
p00007
C++
#include <iostream> #include <cstdio> #include <cstring> using namespace std; long int kane(int k){ long int shakkin = 100000; for(int i=0;i<k;i++){ shakkin = shakkin*1.05; if(shakkin%1000!=0) shakkin += 1000-(shakkin%1000); } return shakkin; } int main() { int n; cin >> n; cout << kane(n) <<endl; return...
a.cc:19:24: error: extended character   is not valid in an identifier 19 | cout << kane(n) <<endl; | ^ a.cc: In function 'int main()': a.cc:19:24: error: expected ';' before '\U00003000' 19 | cout << kane(n) <<endl; | ^~ | ...
s277002250
p00007
C++
p=100000;main(a){for(scanf("%d",&a);a--;p=(p/1000+(p%1000?1:0))*1000)p+=p/20;printf("%d",p);}
a.cc:1:1: error: 'p' does not name a type 1 | p=100000;main(a){for(scanf("%d",&a);a--;p=(p/1000+(p%1000?1:0))*1000)p+=p/20;printf("%d",p);} | ^ a.cc:1:14: error: expected constructor, destructor, or type conversion before '(' token 1 | p=100000;main(a){for(scanf("%d",&a);a--;p=(p/1000+(p%1000?1:0))*1000)p...
s783998611
p00007
C++
import java.util.*;class Main{public static void main(String[]a){System.out.println(f(new Scanner(System.in).nextInt())*1000);}static int f(int n){return n<1?100:(int)Math.ceil(f(n-1)*1.05);}}
a.cc:1:1: error: 'import' does not name a type 1 | import java.util.*;class Main{public static void main(String[]a){System.out.println(f(new Scanner(System.in).nextInt())*1000);}static int f(int n){return n<1?100:(int)Math.ceil(f(n-1)*1.05);}} | ^~~~~~ a.cc:1:1: note: C++20 'import' only available with '-fmod...
s750303249
p00007
C++
#include <iostream> using namespace std; int main(){ int n; scanf("%d",&n); double base = 100000; for(int i=0;i<n;i++){ base*=1.05; } printf("%d\n,(int)base); }
a.cc:10:8: warning: missing terminating " character 10 | printf("%d\n,(int)base); | ^ a.cc:10:8: error: missing terminating " character 10 | printf("%d\n,(int)base); | ^~~~~~~~~~~~~~~~~ a.cc: In function 'int main()': a.cc:11:1: error: expected primary-expression before '}' token 11 |...
s593952828
p00007
C++
import java.util.Scanner; public class Main { public static void main(String arg[]) { Scanner scan = new Scanner(System.in); int n = scan.nextInt(); int de = 100000; for(int i=0; i<n; i++) { de = de / 100; de = de * 105; if(de%1000 != 0) de += 1000; de = de/1000; de = de*1000; } S...
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 | ^~~~~~
s785664926
p00007
C++
#include<iostream> #include<cmath> int main(){ double yami = 100.000; int n; std::cin >> n; for(int i = 0;i < n; ++i){ yami += yami / 20.000; if(ceil(yami) != floor(yami)){ yami = ceil(yami); } } std::cout << yami * 1000 << endl; return 0; }
a.cc: In function 'int main()': a.cc:13:37: error: 'endl' was not declared in this scope; did you mean 'std::endl'? 13 | std::cout << yami * 1000 << endl; | ^~~~ | std::endl In file included from /usr/include/c++/14/iostream:...
s475105656
p00007
C++
#include <iostream> using namespace std; int main() { int n,a = 100000; cin >> n; for(int i=0;i<=n;i++) { a *= 1.05; a += 1000-cur%1000; } cout << a << endl; }
a.cc: In function 'int main()': a.cc:12:23: error: 'cur' was not declared in this scope 12 | a += 1000-cur%1000; | ^~~
s140161799
p00007
C++
#include <iostream> using namespace std; int main() { int n,a = 100000; cin >> n; for(int i=0;i<=n;i++) { a *= 1.05; if(a%1000) a += 1000-cur%1000; } cout << a << endl; }
a.cc: In function 'int main()': a.cc:12:23: error: 'cur' was not declared in this scope 12 | a += 1000-cur%1000; | ^~~
s320004733
p00007
C++
#include <iostream> using namespace std; int main() { int n,a = 100000; cin >> n; for(int i=0;i<n;i++) { a *= 1.05; a += 1000-a%1000; } cout << cur << endl; }
a.cc: In function 'int main()': a.cc:15:13: error: 'cur' was not declared in this scope 15 | cout << cur << endl; | ^~~
s607003304
p00007
C++
#include <iostream> using namespace std; int main() { int n,a = 100000; cin >> n; for(int i=0;i<n;i++) { a *= 1.05; if(a%1000) { a += 1000-a%1000; } } cout << cur << endl; }
a.cc: In function 'int main()': a.cc:17:13: error: 'cur' was not declared in this scope 17 | cout << cur << endl; | ^~~
s647905147
p00007
C++
#i#include <iostream> using namespace std; int main(){ int week,a,b,ans,aans; cin>>week; a=100000*0.05; b=week+1; a*=b; ans=100000+a; aans=ans/1000; aans=ans*1000; if(aans!=ans)ans+100; cout<<ans<<endl; }
a.cc:1:2: error: invalid preprocessing directive #i; did you mean #if? 1 | #i#include <iostream> | ^ | if a.cc: In function 'int main()': a.cc:6:9: error: 'cin' was not declared in this scope 6 | cin>>week; | ^~~ a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; t...
s994703634
p00007
C++
#include<iostream> using namespace std; int main(){ double n; cin >> m; n = 100000; for(int i=0;i<m;i++){ n = n * 1.05; } if(n%1000 > 0) { n = n/1000*1000+1000; } cout << (int)n; return 0; }
a.cc: In function 'int main()': a.cc:6:12: error: 'm' was not declared in this scope 6 | cin >> m; | ^ a.cc:11:9: error: invalid operands of types 'double' and 'int' to binary 'operator%' 11 | if(n%1000 > 0) | ~^~~~~ | | | | | int | dou...
s346766155
p00007
C++
#include<iostream> using namespace std; int main(){ int n; cin >> m; n = 100000; for(int i=0;i<m;i++){ n = n * 1.05; } if(n%1000 > 0) { n = n/1000*1000+1000; } cout << n; return 0; }
a.cc: In function 'int main()': a.cc:6:12: error: 'm' was not declared in this scope 6 | cin >> m; | ^
s126975419
p00007
C++
#include<iostream> using namespace std; int main(void){ int n, ans = 100000; cin >> n; for(i = 0; i < n; i++){ ans = ans * 1.05; if(ans % 1000 != 0); ans = ans - ans % 1000 + 10000; } cout << ans << endl; return 0; }
a.cc: In function 'int main()': a.cc:7:7: error: 'i' was not declared in this scope 7 | for(i = 0; i < n; i++){ | ^
s059696926
p00007
C++
#include <iostream> #include <string> using namespace std; int main(){ int a; a=100000; int b; b=0; while(b<n){ a=a/20*21/1000*1000; b=b+1;} cout << a<<endl; }
a.cc: In function 'int main()': a.cc:10:9: error: 'n' was not declared in this scope 10 | while(b<n){ | ^
s756821565
p00007
C++
#include <iostream> using namespace std; int main() { const double rate = 1.05; int n; while (cin >> n) { double debt = 100; // 100kYen for (int i = 0; i < n; ++i) { debt = ceil(debt * rate); } cout << debt << "000" << endl; } return 0; }
a.cc: In function 'int main()': a.cc:14:32: error: 'ceil' was not declared in this scope 14 | debt = ceil(debt * rate); | ^~~~
s737289034
p00007
C++
#include<iostream> #include<stdio.h> using namespace std; int n; double rent = 100000; int main() { cin>>n; for(int i=0;i<n;i++) { rent = rent * 1.05 ; if( rent % 1000 != 0) rent = rent + 1000; } printf("%.0lf\n",rent); return 0; }
a.cc: In function 'int main()': a.cc:14:27: error: invalid operands of types 'double' and 'int' to binary 'operator%' 14 | if( rent % 1000 != 0) | ~~~~ ^ ~~~~ | | | | double int
s504887306
p00007
C++
#include <stdio.h> int main(){ int n; double debt=100000; scanf("%d",&n); while(n--){ debt += debt*0.05; if(debt%1000!=0){ debt -= debt%1000; debt += 1000; } } printf("%lf\n",debt); return 0; }
a.cc: In function 'int main()': a.cc:8:11: error: invalid operands of types 'double' and 'int' to binary 'operator%' 8 | if(debt%1000!=0){ | ~~~~^~~~~ | | | | | int | double a.cc:9:18: error: invalid operands of types 'double' and 'int' to binary 'operator%' ...
s401350348
p00007
C++
#include <stdio.h> int main(){ int n; double debt=100000.0; scanf("%d",&n); while(n--){ debt += debt*0.05; if(debt%1000!=0){ debt -= debt%1000; debt += 1000; } } printf("%lf\n",debt); return 0; }
a.cc: In function 'int main()': a.cc:8:12: error: invalid operands of types 'double' and 'int' to binary 'operator%' 8 | if(debt%1000!=0){ | ~~~~^~~~~ | | | | | int | double a.cc:9:19: error: invalid operands of types 'double' and 'int' to binary 'operat...
s872519840
p00007
C++
#include <stdio.h> int main(){ int n; double debt=100000; scanf("%d",&n); while(n--){ debt += debt*0.05; if((int)debt%1000!=0){ debt -= debt%1000; debt += 1000; } } printf("%lf\n",debt); return 0; }
a.cc: In function 'int main()': a.cc:9:18: error: invalid operands of types 'double' and 'int' to binary 'operator%' 9 | debt -= debt%1000; | ~~~~^~~~~ | | | | | int | double
s731725103
p00007
C++
p 13530000
a.cc:1:1: error: 'p' does not name a type 1 | p 13530000 | ^
s259668376
p00007
C++
using System; class main { static void Main(String[] args) { double n = double.Parse(Console.ReadLine()); double b = 100000; for (int i = 0; i < n; i++) { b = b * 1.05; b = (Math.Ceiling(b / 1000))*1000; } Console.WriteLine(b); } }
a.cc:1:7: error: expected nested-name-specifier before 'System' 1 | using System; | ^~~~~~ a.cc:4:22: error: 'String' has not been declared 4 | static void Main(String[] args) | ^~~~~~ a.cc:4:31: error: expected ',' or '...' before 'args' 4 | static void Main(S...
s944209084
p00007
C++
using System; class main { static void Main(String[] args) { double n = double.Parse(Console.ReadLine()); double b = 100000; for (int i = 0; i < n; i++) { b = b * 1.05; b = (Math.Ceiling(b / 1000))*1000; } Console.WriteLine(b); //C...
a.cc:1:7: error: expected nested-name-specifier before 'System' 1 | using System; | ^~~~~~ a.cc:5:22: error: 'String' has not been declared 5 | static void Main(String[] args) | ^~~~~~ a.cc:5:31: error: expected ',' or '...' before 'args' 5 | static void Main(S...
s788857403
p00007
C++
#include <iostream> int main(){ int n,debt=100000; for(int i=0;i<(std::cin>>n);i++) debt*=1.05; std::cout<<(debt%1000 ? debt/1000*1000+1000 : debt)<<'\n'; return 0; }
a.cc: In function 'int main()': a.cc:5:22: error: no match for 'operator<' (operand types are 'int' and 'std::basic_istream<char>::__istream_type' {aka 'std::basic_istream<char>'}) 5 | for(int i=0;i<(std::cin>>n);i++) debt*=1.05; | ~^~~~~~~~~~~~~~ | | ...
s161230605
p00007
C++
#include <iostream> int main(){ int n,debt=100000; for(int i=0,cin>>n;i<n;i++) debt*=1.05; std::cout<<(debt%1000 ? debt/1000*1000+1000 : debt)<<'\n'; return 0; }
a.cc: In function 'int main()': a.cc:5:24: error: expected ';' before '>>' token 5 | for(int i=0,cin>>n;i<n;i++) debt*=1.05; | ^~ | ; a.cc:5:24: error: expected primary-expression before '>>' token 5 | for(int i=0,cin>>n;i<n;i++) debt*=1....
s816868906
p00007
C++
#include <iostream> int main(){ int n,debt=100000; cin>>n; for(int i=0;i<n;i++) debt*=1.05; std::cout<<(debt%1000 ? debt/1000*1000+1000 : debt)<<'\n'; return 0; }
a.cc: In function 'int main()': a.cc:5:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'? 5 | cin>>n; | ^~~ | std::cin In file included from a.cc:1: /usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here 62 | extern istream cin; //...
s913905764
p00007
C++
#include <iostream> int main(){ int n,debt=100000; for(int i=0,std::cin>>n;i<n;i++) debt*=1.05; std::cout<<(debt%1000 ? debt/1000*1000+1000 : debt)<<'\n'; return 0; }
a.cc: In function 'int main()': a.cc:5:29: error: qualified-id in declaration before '>>' token 5 | for(int i=0,std::cin>>n;i<n;i++) debt*=1.05; | ^~ a.cc:5:29: error: expected ';' before '>>' token 5 | for(int i=0,std::cin>>n;i<n;i++) debt*=1.05; | ...
s440437915
p00007
C++
#include <iostream> int main(){ int n,debt=100000; std::cin>>n; for(int i=0;i<n;i++){ debt*=1.05; debt=debt%1000 ? debt/1000*1000+1000 : debt } std::cout<<debt<<'\n'; return 0; }
a.cc: In function 'int main()': a.cc:8:60: error: expected ';' before '}' token 8 | debt=debt%1000 ? debt/1000*1000+1000 : debt | ^ | ; 9 | } | ...
s098438637
p00007
C++
#include "stdafx.h" #include <iostream> using namespace std; int main(){ int i,n=100000,m; cin >> i; while(i--){ n+=n*0.05; m=n%1000; if(m){ n+=1000-m; } } cout << n << endl; return 0; }
a.cc:1:10: fatal error: stdafx.h: No such file or directory 1 | #include "stdafx.h" | ^~~~~~~~~~ compilation terminated.
s687487212
p00007
C++
#include <iostream> using namespace std; int main() { double d = 100000.0; int n; cin >> n; for(int i=0; i<n; i++){ d *= 1.05; d /= 1000.0; d = ceil(d); d *= 1000; } cout << (int)d << '\n'; }
a.cc: In function 'int main()': a.cc:12:21: error: 'ceil' was not declared in this scope 12 | d = ceil(d); | ^~~~
s839070277
p00007
C++
#include<iostream> int main(){ int n; double sum=100000; std::cin>>n; for(int i=0;i<n;i++){ sum*=1.05; sum/=1000; sum=std::ceil(sum); sum*=1000; } std::cout<<sum<<std::endl; return 0; }
a.cc: In function 'int main()': a.cc:10:26: error: 'ceil' is not a member of 'std' 10 | sum=std::ceil(sum); | ^~~~
s085338265
p00008
Java
import java.util.Scanner; public class main { public static void main(String[] args) { Scanner in = new Scanner(System.in); while(in.hasNext()){ System.out.println(solve(in.nextInt())); } } static int solve(int n){ int res = 0; for(int i=0;i<10;i++)for(i...
Main.java:3: error: class main is public, should be declared in a file named main.java public class main { ^ 1 error
s316136651
p00008
Java
import java.util.Scanner; class Main{ public static void main(String[] args){ Scanner sc=new Scanner(System.in); while(sc.hasNextInt()){ int n=sc.nectInt(); int num=0; for(int a=0;a<=9;a++){ for(int b=0;b<=9;b++){ for(int c=0;c<=9;c++){ if(binary_search(n-a-b-c)){ num++; } } } } System.out.println(num); } } public sta...
Main.java:24: error: ';' expected n[a]=a ^ 1 error
s632139086
p00008
Java
import java.util.Scanner; class Main{ public static void main(String[] args){ Scanner sc=new Scanner(System.in); while(sc.hasNextInt()){ int n=sc.nectInt(); int num=0; for(int a=0;a<=9;a++){ for(int b=0;b<=9;b++){ for(int c=0;c<=9;c++){ if(binary_search(n-a-b-c)){ num++; } } } } System.out.println(num); } } public sta...
Main.java:7: error: cannot find symbol int n=sc.nectInt(); ^ symbol: method nectInt() location: variable sc of type Scanner Main.java:22: error: incompatible types: int[] cannot be converted to int int n=new int[10]; ^ Main.java:24: error: array required, but int found n[a]=a; ^ Main.java:30: error...
s052462367
p00008
Java
import java.util.Scanner; class Main{ public static void main(String[] args){ Scanner sc=new Scanner(System.in); while(sc.hasNextInt()){ int n=sc.nextInt(); int num=0; for(int a=0;a<=9;a++){ for(int b=0;b<=9;b++){ for(int c=0;c<=9;c++){ if(binary_search(n-a-b-c)){ num++; } } } } System.out.println(num); } } public sta...
Main.java:30: error: cannot find symbol if(x==a[i]){ ^ symbol: variable a location: class Main Main.java:33: error: cannot find symbol else if(x>a[i]){ ^ symbol: variable a location: class Main Main.java:36: error: cannot find symbol else if(x<a[i]){ ^ symbol: variable a loca...
s528200639
p00008
Java
public class Demo{ public int sumAll(int...numbers){ int result = 0; for(int i = 0 ; i<numbers.length;i++){ result+=numbers[i]; } return result; } }
Main.java:1: error: class Demo is public, should be declared in a file named Demo.java public class Demo{ ^ 1 error
s249589525
p00008
Java
import java.util.*; public class Main{ private static final Scanner scan = new Scanner(System.in); public static void main(String[] args){ List<Integer> list = new ArrayList<Integer>(); int cnt = 0; while(scan.hasNext()){ for(int i = 0; i <= 9; i++){ for(int j = 0; j <= 9; j++){ for(int k = 0; k <...
Main.java:14: error: cannot find symbol if(i + j + k + l == n){ ^ symbol: variable n location: class Main 1 error
s656455401
p00008
Java
import java.util.Scanner; public class vol0_0008 { public static void main(String[] a) { final int max = 10; Scanner scn = new Scanner(System.in); int n = scn.nextInt(); long ans = 0; for (int w = 0; w < max; w++) { if(n - w > (max - 1) * 3)continue; for (int x = w; x < max; x++) { if(n - w - x > ...
Main.java:3: error: class vol0_0008 is public, should be declared in a file named vol0_0008.java public class vol0_0008 { ^ 1 error
s016475535
p00008
Java
import java.util.Scanner; public class Sumof4Integers { public static void main(String[] args) { int aList[] = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 }; int bList[] = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 }; int cList[] = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 }; int dList[] = { 0, 1, 2, 3, 4, 5, 6, 7, 8...
Main.java:3: error: class Sumof4Integers is public, should be declared in a file named Sumof4Integers.java public class Sumof4Integers { ^ 1 error
s774923475
p00008
Java
import java.util.Scanner; import volume0.BaseExe; public class Work extends BaseExe { public static void main(String[] args) { new Work().exeSysIn(); } @Override protected void execute(Scanner scan) { int[] num = new int[51]; for (int a = 0; a <= 9; a++) for (int b...
Main.java:4: error: class Work is public, should be declared in a file named Work.java public class Work extends BaseExe { ^ Main.java:2: error: package volume0 does not exist import volume0.BaseExe; ^ Main.java:4: error: cannot find symbol public class Work extends BaseExe { ...
s786103551
p00008
Java
public class Mian { public static void main(String[] args) { int count = 0; int n = new java.util.Scanner(System.in).nextInt(); for (int a = 0; a < 10; a++) { for (int b = 0; b < 10; b++) { for (int c = 0; c < 10; c++) { for (int d = 0; d < 10; d++) { if (a + b + c + d == n) { count++; ...
Main.java:1: error: class Mian is public, should be declared in a file named Mian.java public class Mian { ^ 1 error
s175447713
p00008
Java
public class Mian { public static void main(String[] args) { int count = 0; int n = new java.util.Scanner(System.in).nextInt(); for (int a = 0; a < 10; a++) { for (int b = 0; b < 10; b++) { for (int c = 0; c < 10; c++) { for (int d = 0; d < 10; d++) { if (a + b + c + d == n) { count++; ...
Main.java:1: error: class Mian is public, should be declared in a file named Mian.java public class Mian { ^ 1 error
s523874462
p00008
Java
public class Mian { static int n = new java.util.Scanner(System.in).nextInt(); public static void main(String[] args) { int count = 0; for (int a = 0; a < 10; a++) { for (int b = 0; b < 10; b++) { for (int c = 0; c < 10; c++) { for (int d = 0; d < 10; d++) { if (a + b + c + d == n) { cou...
Main.java:1: error: class Mian is public, should be declared in a file named Mian.java public class Mian { ^ 1 error
s493911720
p00008
Java
public class Mian { static int n = new java.util.Scanner(System.in).nextInt(); static int count = 0; public static void main(String[] args) { for (int a = 0; a < 10; a++) { for (int b = 0; b < 10; b++) { for (int c = 0; c < 10; c++) { for (int d = 0; d < 10; d++) { if (a + b + c + d == n) { ...
Main.java:1: error: class Mian is public, should be declared in a file named Mian.java public class Mian { ^ 1 error
s736743158
p00008
Java
import java.util.Scanner; class Problem { public static int sumOf4Int(int n){ int count = 0; if(n > 36){ return 0; } for(int a = 0; a < 10; a ++){ for(int b = 0; b < 10; b ++){ for(int c = 0; c < 10; c ++){ for(int d = 0; ...
Main.java:24: error: incompatible types: String cannot be converted to int System.out.println(sumOf4Int(args[1])); ^ Note: Some messages have been simplified; recompile with -Xdiags:verbose to get full output 1 error