Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
147920 张锦程 财务管理 C++ Compile Error 0 MS 0 KB 252 2026-02-09 08:39:34

Tests(0/0):


Code:

#include<iostream> using namespace std; int main(){ double n; double a[12]={}; for(int i=0;i<12;i++){ cin>>a[i]; } for(int i=0;i<12;i++){ n+=a[i]; }n=n/12; printf("%.2lf","¥",n) return 0; }


Run Info:

Main.cc: In function 'int main()':
Main.cc:12:27: warning: format '%lf' expects argument of type 'double', but argument 2 has type 'const char*' [-Wformat=]
     printf("%.2lf","¥",n)
                           ^
Main.cc:12:27: warning: too many arguments for format [-Wformat-extra-args]
Main.cc:13:5: error: expected ';' before 'return'
     return 0;
     ^