A - Watermelon
Problem Link: [Codeforces 4A##link##]
- [tab]
- C++
#include <bits/stdc++.h> using namespace std; int main() { int a; cin >> a; if (a%2 !=0 || a== 2) cout << "NO"; else cout << "YES"; }
- Python3
w = int(input()) if w%2 == 0 and w != 2: print("YES") else: print("NO")
- JAVA
import java.util.Scanner; public class Solution { public static void main(String[] args) { // TODO Auto-generated method stub Scanner scanner = new Scanner(System.in); int w = scanner.nextInt(); scanner.close(); if (w > 2 && w % 2 == 0) System.out.println("YES"); else System.out.println("NO"); } }