Learning Python: AND/OR conditions - Deepstash
Learning Python: AND/OR conditions

Learning Python: AND/OR conditions

As you can see in the image there is 2 tables, 1 means true and 0 means false.

As you can see AND needs both to be true to be True, and OR only needs one to be true to be True.

When you create a condition for a loop or for a condition, you can add as many conditions as you want as long over all it will return a boolean value. So imagine not using a AND/OR and you make 10 if statements to check each condition, well with this you can do it in one statement.

Something new for you, in the second statement its returned True, why? answer on discord or leave a comment on why you think its True

2

29 reads

CURATED FROM

IDEAS CURATED BY

samuelbancroft

Keep reading, keep studying, the more you learn the more you change. If you are doing the Python lessons please join this discord channel https://discord.gg/kugXx9KY but please follow the rules

Lets look at the importance of AND/OR's

Similar ideas to Learning Python: AND/OR conditions

Learning Python: IF statements

Learning Python: IF statements

As you can see in the image, we are working with conditional if statements. This is used to find out if something is True or False. As you can see i used '

Learning Python: Basic Mathematical Operators error

Learning Python: Basic Mathematical Operators error

So as you can see from the image we are using 2 variables, x and y. Like in the previous lessons explained about variables, x contains the string Hello World, what makes it a string is " " the use of these quotation marks. Next in y there is a integer value 10. Then i am adding them both together...

The 3 levels of a company culture

The 3 levels of a company culture

  • Artifacts - things you can see, touch, smell: Ping pong tables, happy hours, and free lunches.
  • Espoused values and beliefs - the mission statement you wrote together as a company or the code of conduct that’s in your employee handbook.
  • Basic underlying assum...

Read & Learn

20x Faster

without
deepstash

with
deepstash

with

deepstash

Personalized microlearning

100+ Learning Journeys

Access to 200,000+ ideas

Access to the mobile app

Unlimited idea saving

Unlimited history

Unlimited listening to ideas

Downloading & offline access

Supercharge your mind with one idea per day

Enter your email and spend 1 minute every day to learn something new.

Email

I agree to receive email updates