奇偶判斷
需求如下:

代碼如下:
1 #include <iostream>
2 using namespace std; 3 int main() 4 { 5 int n; 6 cin>>n; 7 if(n%2==0) cout<<n<<" is even."<<endl; 8 else cout<<n<<" is odd."<<endl; 9 return 0; 10 }
寫在最后:
哪里有不足或者錯誤的地方,歡迎小伙伴們進行指教,一起進步哦!
