初学 C++,遇到了 liner-gcc 的错误提示,求指点
PHP中文网
PHP中文网 2017-04-17 15:02:46
0
1
521
#include "iostream"
using namespace std;
int main() {
    int arr[1000];
    int j = 0;
    std::cin >> j;
    for (size_t i = 0; i < j; i++) {
        std::cin >> arr[i];
    }

    for (size_t i = 0; i < j; i++) {
        for (size_t m = 0; m < j; m++) {
            if (arr[i] < arr[m]) {
                int a = arr[m];
                arr[m] = arr[i];
                arr[i] = a;
            }
        }
    }

    for (size_t i = 0; i < j; i++) {
        std::cout << arr[i] << endl;
    }
    std::cout << '\n' << endl;
    return 0;
}

liner-gcc报错了:

自己琢磨可能是哪里写的不规范,求指点

PHP中文网
PHP中文网

认证0级讲师

reply all(1)
阿神

My compiler can run and bubbles normally...

The error message is Permission denied, which means it is a permission problem

It has nothing to do with your code

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!