Задача 13 Урок 9

Задача 13 Урок 9

У вас есть три числа (три переменные) найдите их медиану(link is external).

var
   a,b,c : integer;

begin
    writeln ('Vvedite chislo A ');
    readln(a);
    writeln ('Vvedite chislo B ');
    readln(b);
    writeln ('Vvedite chislo C ');
    readln(c);
       if ((b<a) and (b>c)) then
           writeln ('Mediana chisel ',b);
       if ((a>b) and (a<c)) then
           writeln ('Mediana chisel ',a);
       if ((c<b) and (c>a)) then
           writeln ('Mediana chisel ',c);
    readln();
 end.