From 6fd78895ce8131fda904bff5b0fd2e14367d4b7c Mon Sep 17 00:00:00 2001 From: ANUJ YADAV <52133014+ANUJ581@users.noreply.github.com> Date: Sun, 6 Oct 2019 10:08:46 +0530 Subject: [PATCH 1/2] Add files via upload --- 4A.java | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 4A.java diff --git a/4A.java b/4A.java new file mode 100644 index 0000000..78c872c --- /dev/null +++ b/4A.java @@ -0,0 +1,18 @@ +import java.util.*; +import java.lang.*; +import java.io.*; + + +public class Codechef +{ + public static void main (String[] args) throws java.lang.Exception + { + Scanner in = new Scanner(System.in); + int n = in.nextInt(); + if(n> 2 && n % 2 == 0) + System.out.println("YES"); + else + System.out.println("NO"); + + } +} \ No newline at end of file From 5215ecb97b03df04381ec4616f6a3c46cc9ed7bf Mon Sep 17 00:00:00 2001 From: ANUJ YADAV <52133014+ANUJ581@users.noreply.github.com> Date: Fri, 2 Oct 2020 19:56:39 +0530 Subject: [PATCH 2/2] updated scanner --- 4A.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/4A.java b/4A.java index 78c872c..de9f378 100644 --- a/4A.java +++ b/4A.java @@ -7,12 +7,12 @@ public class Codechef { public static void main (String[] args) throws java.lang.Exception { - Scanner in = new Scanner(System.in); - int n = in.nextInt(); + Scanner sc = new Scanner(System.in); + int n = sc.nextInt(); if(n> 2 && n % 2 == 0) System.out.println("YES"); else System.out.println("NO"); } -} \ No newline at end of file +}