- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- MS Excel
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP
- Physics
- Chemistry
- Biology
- Mathematics
- English
- Economics
- Psychology
- Social Studies
- Fashion Studies
- Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Malhar Lathkar has Published 50 Articles
Malhar Lathkar
228 Views
In Python, is and is not operators are called identity operators. Each object in computer's memory is assigned a unique identification number (id) by Python interpreter. Identity operators check if id() of two objects is same. 'is not' operator returns true of id() values are different and false if they ... Read More
Malhar Lathkar
485 Views
In Python, in and not in operators are called membership operators. Their purpose is to check if an object is a member of a certain sequence object like string, list, or tuple. The in operator returns true if object is present in sequence, false if not found>>> 'p' in 'Tutorialspoint' ... Read More
Malhar Lathkar
211 Views
In Python, in and not in operators are called membership operators. Their purpose is to check if an object is a member of a certain sequence object like string, list, or tuple. The not in operator returns false if object is present in sequence, true if not found>>> 'p' not ... Read More
Malhar Lathkar
9K+ Views
In Python >> is called right shift operator. It is a bitwise operator. It requires a bitwise representation of object as first operand. Bits are shifted to right by number of bits stipulated by second operand. Leading bits as towards left as a result of shifting are set to 0.>>> ... Read More
Malhar Lathkar
349 Views
The % symbol is defined in Python as modulo operator. It can also be called remainder operator. It returns remainder of division of two numeric operands (except complex numbers).>>> a=10 >>> b=3 >>> a%b 1 >>> a=12.25 >>> b=4 >>> a%b 0.25 >>> a=-10 >>> b=6 >>> a%b 2 >>> a=1.55 >>> b=0.05 >>> a%b 0.04999999999999996
Malhar Lathkar
7K+ Views
The logical operators and, or and not are also referred to as boolean operators. While and as well as or operator needs two operands, which may evaluate to true or false, not operator needs one operand evaluating to true or false.Boolean and operator returns true if both operands return true.>>> ... Read More
Malhar Lathkar
1K+ Views
In Python or is a logical operator and | is a bitwise operator. The or operator requires two opeans of any type and may be true or false. It returns true if any one operand evaluates to true.>>> a=50 >>> b=25 >>> a>40 or b>40 True >>> a>100 or b>> ... Read More
Malhar Lathkar
5K+ Views
In Python, and and or (along with not) are defined as logical operators. Both require two operands which may evaluate to true or false.The and operator returns True only if both operands are True.>>> a=50 >>> b=25 >>> a>40 and b>40 False >>> a>100 and b>> a==0 and b==0 False ... Read More
Malhar Lathkar
149 Views
Ternary operator was added in Python 2.5. Its syntax is:Syntaxx if expr==True else yExampleFollowing example illustrates usage>>> percent=59 >>> 'pass' if percent>=50 else 'fail' 'pass' >>> percent=45 >>> 'pass' if percent>=50 else 'fail' 'fail'
Malhar Lathkar
118 Views
Complex number is made up of real and imaginary parts. Real part is a float number, and imaginary part is any float number multiplied by square root of -1 which is defined as j.>>> no=5+6j >>> no.real 5.0 >>> no.imag 6.0 >>> type(no) The resulting object is of complex data ... Read More