Python not operator:

  • python not operator is the complement of the given value i.e; if the value is true then it returns false and if the value is false then it returns true.
  • When we  apply the not operator we get result  in  boolean type .
  • example:
                 x=10 
                 not x, then the result is false because x=10 is true so not x is false.
  • syntax:(not x).

 # write a python program using not operator.

  1. x="python"
  2. y="java''
  3. print(not x==y)
output: true

 

Instance Of Java

We will help you in learning.Please leave your comments and suggestions in comment section. if you any doubts please use search box provided right side. Search there for answers thank you.
«
Next
Newer Post
»
Previous
Older Post

No comments

Leave a Reply

Select Menu