Selection Test 1


Submit solution

Points: 1 (partial)
Time limit: 1.0s
Memory limit: 98M

Author:
Problem type
Allowed languages
Ada, Assembly, Awk, C, C++, C11, CLANG, CLANGX, Classical, COBOL, Coffee, CSC, D lang, DART, F95, FORTH, Fortrn, GAS32, GO, Haskell, Itercal, Java, kotlin, LEAN, LISP, LUA, MONOVB, Nasm, OCAML, Pascal, Perl, php, PIKE, prolog, Pypy, Python, Ruby 2, RUST, Scala, SCM, SED, SWIFT, TCL, TUR, V8JS, VB, ZIG

Read 4 integer values A, B, C and D. Then if B is greater than C and D is greater than A and if the sum of C and D is greater than the sum of A and B and if C and D were positives values and if A is even, write the message “Chap nhan” (Accepted values). Otherwise, write the message “Khong chap nhan” (Values not accepted).

Input

Four integer numbers A, B, C and D.

Output

Show the corresponding message after the validation of the values​​.

SAMPLE 1

INPUT 1

5 6 7 8

OUTPUT 1

Khong chap nhan

SAMPLE 2

INPUT 2

2 3 2 6

OUTPUT 2

Chap nhan


Comments


  • 0
    TICHPX  commented on Nov. 28, 2023, 3:17 p.m.

    Khi up code nhớ cho vào trong cum ba dấu ` như ví dụ sau nhé

    Đăng code vào đây

  • 0
    tunga04102005  commented on Nov. 28, 2023, 2:52 p.m.
    #include<stdio.h>
    int main()
    {
        int A,B,C,D;
        scanf("%d%d%d%d",&A,&B,&C,&D);
        if(B>C && D>A && C+D>A+B && C >0 && D>0 && A%2==0){
            printf("Chap nhan");
        }
    
        else{
        printf("Khong chap nhan");
        }
    }