Git Product home page Git Product logo

python-introductory's Introduction

BÀI TẬP

  1. Viết hàm in lời chào mừng khách hàng như sau:
    1. Hàm nhận vào họ của khách hàng, tên đệm và tên gọi, danh xưng (Mr. hoặc Ms.). Lưu ý: họ, tên và tên đệm là 2 biến khác nhau.
    2. In ra lời chào với danh xưng và họ. Ví dụ: "Xin chào Mr. Nguyen"
    3. In ra câu thông báo: "Tên in trên vé của bạn là họ-và-tên". Ví dụ: "Tên in trên vé của bạn là Nguyen Van A”.
  2. Cũng với hàm trên, nhưng thêm vào biến global cho phép tăng số ghế của hành khách, bắt đầu từ 99. Ví dụ:
    1. Sau khi gọi hàm với khách hàng Nguyen Van A, in thêm câu: "Số ghế của bạn là 100".
    2. Tiếp tục gọi hàm với khách hàng Tran Van B, in thêm câu: "Số ghế của bạn là 101".
  3. Tiếp tục bổ sung hàm trên, nhận thêm thông tin về năm sinh của khách hàng. In ra tuổi của khách hàng. Ví dụ: "Bạn năm nay 20 tuổi" (khi nhận nam_sinh = 2002).

python-introductory's People

Contributors

tynab avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.