• 2022-06-05
    下面程序用于计算f,n)=1+2++n,其中power(m,n)求m”。请填写程序中相应语句。[br][/br]include [br][/br]int power(int m,int n){[br][/br]int i;[br][/br][input=type:blank,size:4][/input];for(i=1;i<=n;i+)[br][/br][input=type:blank,size:4][/input];return p;}int f(int k,int n)[br][/br]{[br][/br]int i[br][/br][input=type:blank,size:4][/input];for(i=1;i<=n;i++)[br][/br][input=type:blank,size:4][/input];return s;}int main(void)[br][/br]{intk,n;[br][/br]scanf"%d%d",&k,&n);[br][/br]printf“f(%d,%d)-%ld”,k,n,fk,n);[br][/br]return 0;[br][/br]}[br][/br]
  • 举一反三