Commit 5c21796 authored Jun 26, 2024 · 3 / 3 · Verified
1 parent c3c6913 commit 5c21796 Copy full SHA for 5c21796
File tree 1 file changed +8
-9
lines changed
1 file changed +8
-9
lines changed Original file line number Diff line number Diff line change @@ -34,39 +34,38 @@ int main() {
34
34
```
35
35
36
36
</CPPSection >
37
-
38
37
<JavaSection >
39
38
40
39
``` java
41
40
import java.io.* ;
42
41
import java.util.* ;
42
+
43
43
public class Watermelon {
44
44
public static void main (String [] args ) {
45
45
Kattio io = new Kattio ();
46
- int s = io. nextInt();
47
- if (s % 2 == 0 && s > 2 ) {
46
+ int w = io. nextInt();
47
+ if (w % 2 == 0 && w > 2 ) {
48
48
io. println(" YES" );
49
49
} else {
50
50
io. println(" NO" );
51
51
}
52
52
io. close();
53
53
}
54
+
54
55
// CodeSnip{Kattio}
55
56
}
56
57
```
57
58
58
59
</JavaSection >
59
-
60
60
<PySection >
61
61
62
62
``` py
63
- num = int (input ())
64
- if num % 2 != 0 or num <= 2 :
65
- print (" NO" )
66
- else :
63
+ w = int (input ())
64
+ if w % 2 == 0 and w > 2 :
67
65
print (" YES" )
66
+ else :
67
+ print (" NO" )
68
68
```
69
69
70
70
</PySection >
71
-
72
71
</LanguageSection >
You can’t perform that action at this time.
0 commit comments