Python Basics
Basics
Operators
Basics
Conditional Statements
100

one of the easiest programming languages
to learn

what is

python

100

the keyword for getting an answer from the user

what is

input()

100

Name 3 relational operators

<

>

<=

!=

==

100

the area we write code in Python

console

100

Name 3 conditional statements

simple if

if else

if elif else

nested if

200

colors of the python logo

what is 

blue and yellow

200

the function used to to show something on the screen

what is

print()

200

Arithmetic Operators (any 3)

+, - , *, / , //, %

200

Is this a valid variable name?

_TotalMarks


Yes

200

What is the result of any condition?

Either true or false

300

Who developed Python

Guido Van Rossum


300

What is a variable

A container to store the values

300

How to assign value to a variable?

with the help of equal sign

300

What is IDLE

Integrated Development and Learning Environment

300

x = 5

if x > 2:

    if x < 10:

        print("A")

    else:

        print("B")

else:

    print("C")


A

400

Comments in Python starts with

#

400

What is the purpose of print()

Used to print on the screen

400
Name two logical operators.

and, or, not

400

Python uses a compiler or interpreter

interpreter

400

num = 0

if num:

    print("True block")

else:

    print("False block")

False - else block

500

the file extension for python files

what is

.py

500

comments in python start with

what is

#

500

What is a modulus division operator

%

500

What is syntax

Rules/Format for writing python statements

500

x = 10

y = 5

if x > y and x < 15:

    print("Condition 1 True")

elif y == 5 or x == 5:

    print("Condition 2 True")

else:

    print("No condition True")


Condition 1 True