阅读背景:

为什么我无法以长数据类型存储数据?

来源:互联网 
int power(int first,int second) {
    int counter1 = 0;
    long ret = 1;

    while (counter1 != second){
        ret *= first;
        counter1 += 1;
    }
    return ret;
}


int main(int argc,char **argv) {

    long one = atol(argv[1]);
    long two = atol(argv[2]);
    char word[30];
    long finally;

    printf("What is the operation? 'power','factorial' or 'recfactorial'\n");
    scanf("%20s",word);

    if (strcmp("power",word) == 0){
        finally = power(one,two);
        printf("%ld\n",finally);
        return 0;
    } 

}
int power(int first,int second) {
    int count



你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: