#CCBCMCHIN0000041. Trung bình 3 (Average 3)

Trung bình 3 (Average 3)

Average 3

Source: beecrowd

Version: Phuoc Hung OJ Extended

Problem Statement

Four scores have weights 2,3,4,12,3,4,1. Compute M=(2N1+3N2+4N3+N4)/10M=(2N_1+3N_2+4N_3+N_4)/10. A student passes when M≥7M\ge7, fails when M<5M<5, and takes a retake when 5≤M<75\le M<7. In the retake case, read EE, compute F=(M+E)/2F=(M+E)/2, and pass iff F≥5F\ge5. Use the exact Portuguese output labels specified below.

Input

The first line contains four scores N1,N2,N3,N4N_1,N_2,N_3,N_4. If a retake is required, the next line contains the retake score EE.

Output

First print Media: X.X. If M≥7M\ge7, print Aluno aprovado.; if M<5M<5, print Aluno reprovado.. For a retake, print Aluno em exame., then Nota do exame: X.X, then Aluno aprovado. or Aluno reprovado. according to the final average, and finally Media final: X.X. Every displayed number has exactly one decimal digit.

Subtasks

Subtask 1 (20 points): Scores are in [0,10] with one decimal digit and the initial average is >= 7; no retake score. Subtask 2 (30 points): Scores are in [0,10] with one decimal digit and the initial average is < 5; no retake score. Subtask 3 (50 points): Scores are in [0,10] with one decimal digit; a retake score in [0,10] follows only when 5 <= the initial average < 7.

Examples

Example 1

Input

5 5 5 5
5

Output

Media: 5.0
Aluno em exame.
Nota do exame: 5.0
Aluno aprovado.
Media final: 5.0

Explanation

The weighted mean is 5.0. The retake mark is 5.0, so the final mean is 5.0 and the student passes.

Example 2

Input

7 7 7 7

Output

Media: 7.0
Aluno aprovado.

Explanation

The initial mean is exactly 7.0, so the student passes without a retake.