Bài toán Pascal: Viết chương trình giải bất phương trình bậc 1 (ax + b > 0)

Bài toán Pascal: Viết chương trình giải bất phương trình bậc 1 (ax + b > 0)

Viết chương trình giải bất phương trình bậc 1 (ax + b > 0) 

Program BAT_PHUONG_TRINH_BACI;

Uses crt;

Var a,b: real; 

Begin

  Clrscr;

  Writeln('GIAI BAT PHUONG TRINH BAC NHAT: AX + B>=0'); 

  Writeln('----------------------------------------------------------------------'); 

  Write('nhap a=');

  readln(a);

  Write('nhap b=');

  readln(b); 

  If a<>0 then

    If a>0 then 

      Writeln('Bat phuong trinh co nghiem: x>=',-b/a:4:2) 

    Else 

      Writeln('Bat phuong trinh co nghiem: x<=',-b/a:4:2)

  Else

    If b>=0 then 

      Writeln('Bat phuong trinh co vo so nghiem') 

    Else 

      writeln('Bat phuong trinh vo nghiem');

    Readln;

End.
Bạn thấy bài viết này như thế nào?: 
Average: 1.8 (51 votes)
Ảnh của Tommy Tran

Tommy owner Express Magazine

Drupal Developer having 9+ year experience, implementation and having strong knowledge of technical specifications, workflow development. Ability to perform effectively and efficiently in team and individually. Always enthusiastic and interseted to study new technologies

  • Skype ID: tthanhthuy

Advertisement

 

jobsora

Dich vu khu trung tphcm

Dich vu diet chuot tphcm

Dich vu diet con trung

Quảng Cáo Bài Viết

 
Android, Google, Google App Engine, Google Play

Hướng dẫn cài đặt các ứng dụng Android không tương thích từ Google Play

Một số ứng dụng Android trên Google Play không tương thích với tất cả các loại thiết bị khác nhau.

DroidSecurity phần mềm diệt virus miễn phí cho Android

DroidSecurity phần mềm diệt virus miễn phí cho Android

Trình diệt virus dành riêng cho Android này đã được hơn 4.5 triệu người tin tưởng sử dụng.

Use the Drupal Widgets Module For Reusable Content

Sử dụng Drupal Widgets Module để nhân bản 1 nội dung

The Widgets module allows you to centrally manage text and code snippets across your Drupal site.

Công ty diệt chuột T&C

 

Diet con trung