#include #include #include using namespace std;

int main() { int n; cin >> n; vector nums(n); for (int i = 0; i < n; i++) { cin >> nums[i]; } int minNum = *min_element(nums.begin(), nums.end()); for (int i = 0; i < n; i++) { if (nums[i] != minNum) { cout << nums[i] << " "; } } cout << endl; return 0; }

时间限制:CC++ 1000MS其他语言 2000MS内存限制:CC++ 16MB其他语言 32MB难度:中等出题人:描述在一个不重复的数组中请将这个数组的最小数删除后输出!输入描述有两行 第一行有一个整数n 5 = n = 100 第二行有n个不重复的整数!输出描述删除最小数后的数组!

原文地址: https://www.cveoy.top/t/topic/iEQl 著作权归作者所有。请勿转载和采集!

免费AI点我,无需注册和登录