0% found this document useful (0 votes)
30 views2 pages

Python Class 11

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
30 views2 pages

Python Class 11

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 2

*Python character set:-character set is a set of vaild characters recognized by

python.A character represents any letter,digit or other symbol.


1.Letter- A-Z,a-z
2.digits-0-9
3.special symbols-!@#$%^&*()_+=-0';/.,":?><[]{}
4.whitespaces-blank space(' '),tabs(|t),carriage return,newline,formfeed.
5.other characters- all other 256 ASC11 and unicorn characters.

*tokens:- a tokens is the smallest element of a python script that is meaningful to


the interpreter.

*Indentifiers:-indentifiers are the name used to give an indentity a


variable ,function,class,object,arrays and etc.
1.Identifiers can be a combination of letters in lower case (a to z) or upercase (A
to Z) or digit (0 to 9)or an underscore_name.
2.An indentifiers cannot start with a digit 1 variable is invaild but variable 1
is a vaild name.
3.Keywords cannot be used as indentifiers.
4.we cannot use special as indentifiers.
5.An indentifiers can be of any length

*keywords:-the reserved words in python,which have a special fixed meaning for the
interpreter,are called keywords.

*literals|constant:- a fixed numeric or non-numeric value is called a literal.it


can as a no.,text, or other data that represent values to be stored in variables.

*Operators:-an operator is a symbol or a word that performs some kind of operation


on the given vales and return the result.

*punctuators|delimiters:-delimiters are the symbols which can be used as seperators


of the valie or to enclose some values.

note:-# symbol used to insert comments is not token.

*operators:-
1.arithmetic operators
2.assignment operators
3.comparison operators
4.logical operators
5.indentity operators
6.membership operators

1.arithmetic operators - +,-,*,%,**,//

2.assignment operators-=,+=,-=

3.comparison operatirs-
==-equal
!=-not equal
>-greater than
<-less than
>=-greater than or equal to
<=-less than or equal to

4.logical operator-
and-return true it both statements are true
or-return true if one of them statement is true
not-return the result return false if the statement result is true
5.memebership operator-
in- return true if a sequence with the specified value is present in the object.
not in-return true if a sequence with the specified value is not present in the
object.

6.indentify operator-
is- return true if the both variables are the same object.
is not-return true if both variables are not the same object.

7.bitwise operator-
&-
!-
^-

You might also like