三色球问题
1 #include <iostream> 2 using namespace std; 3 int main() 4 { 5 int count=0; 6 for(int i=0;i<=3;i++) 7 { 8 for(int j=0;j<=3;j++) 9 { 10 for(int k=0;k<=6;k++) 11 { 12 if(i+k+j==8) 13 { 14 count++; 15 } 16 } 17 } 18 } 19 cout<<count<<endl; 20 } 21
标签:std,count,语言,int,编程,趣味 From: https://www.cnblogs.com/Lyh3012648079/p/17417895.html