Python learning log for small y-Process Control (logical character)

Source: Internet
Author: User

#本文仅为个人学习过程的整理和记录, if there is a blog from others, the site extracts the content, I will clearly mark, if there is infringement, please contact me, I will be deleted in the first time.

The following information is compiled from the (1) Liaoche python tutorial http://www.liaoxuefeng.com/wiki/001374738125095c955c1e6d8bb493182103fac9270762a000

(2) Concise python tutorial http://woodpecker.org.cn/abyteofpython_cn/chinese/

(1) Logical operator and

X=int (Input (' Please input x: '))
Y=int (Input (' Please input y: '))
If X>=60 and y>=60:
   Print (' good ')
Else
   Print (' bad ')

(2) Logical operator or

X=int (Input (' Please input x: '))
Y=int (Input (' Please input y: '))
If x>=80 or y>=80:
   Print (' good ')
Else
   Print (' bad ')

(3) Logical operator not

def fun ():
   return 0
X=int (Input (' Please input x: '))
Y=int (Input (' Please input y: '))
If not fun ():
   Print (' OK ')

Python learning log for small y-Process Control (logical character)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.