Advertisement
Guest User

Untitled

a guest
Sep 21st, 2019
86
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.07 KB | None | 0 0
  1. program laba_1_1 ;
  2.  
  3. {$APPTYPE CONSOLE}
  4.  
  5. uses
  6. SysUtils;
  7.  
  8. var
  9. x,y:Double;
  10. IsCorrect:Boolean;
  11.  
  12. begin
  13. Writeln('Введите значения x в диапозоне от 0 до 2 , у в диапазоне от 0 до 1 ');
  14. IsCorrect:= False;
  15. repeat
  16. Writeln('Введите x');
  17. try
  18. Readln(x);
  19. IsCorrect:=True;
  20. except
  21. On E: EInOutError do
  22. Writeln('Пожалуйства, введите другое число');
  23. end;
  24. until IsCorrect and (x>0);
  25. IsCorrect:= False;
  26. repeat
  27. Writeln('Введите y');
  28. try
  29. Readln(y);
  30. IsCorrect:=True;
  31. except
  32. On E: EInOutError do
  33. Writeln('Пожалуйства, введите другое число');
  34. end;
  35. until IsCorrect and (y>0);
  36. if(x>0) and (x<2) and (y<(-1/2)*x+1) and (y>0) then
  37. Writeln('Данная точка принадлежит множеству')
  38. else
  39. Writeln('Данная точка не принадлежит множеству');
  40. Readln;
  41. end.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement