Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
76438 揭伟琦 13求n的阶乘 C++ Compile Error 0 MS 0 KB 158 2024-06-02 14:31:12

Tests(0/0):


Code:

#include<bits/stdc++.h> using namespace std; int main(){ int n,sm=1; cin>>n; for (int i=1;i<=n;i++) { sm =sm i*; } cout <<sm; return 0; }


Run Info:

Main.cc: In function 'int main()':
Main.cc:7:11: error: expected ';' before 'i'
   sm =sm  i*;
           ^