Run ID:153481
提交时间:2026-05-17 16:25:27
#include <iostream> using namespace std; int main() { int a[] = {2,4,6,8}; int cnt = 0; // 三重循环枚举三位不同下标 for(int i=0;i<4;i++) { for(int j=0;j<4;j++) { for(int k=0;k<4;k++) { if(i!=j && j!=k && i!=k) { cout << a[i] << a[j] << a[k] << endl; cnt++; } } } } cout << cnt << endl; return 0; }