Math, asked by vasurgukt9342, 1 year ago

Write a function that has one integer argument and returns 0 if number is even else returns 1.

Answers

Answered by ryan567
2
hey mate ur ans

using namespace std; int main() { int n; cout << "Enter an integer: "; cin >> n; if ( n % 2 == 0) cout << n << " is even."; else cout << n << " is odd."; return 0; }


hope it helps
Similar questions