#14 Python Tutorial for Beginners | Python BitWise Operators

Поділитися
Вставка
  • Опубліковано 9 лют 2025
  • Check out our courses:
    Java Full Stack and Spring AI - go.telusko.com...
    Coupon: TELUSKO10 (10% Discount)
    DevOps with AWS: From Basics to Mastery : go.telusko.com...
    Coupon: TELUSKO10 (10% Discount)
    Master Java Spring Development : go.telusko.com...
    Coupon: TELUSKO20 (20% Discount)
    Udemy Courses:
    Spring: go.telusko.com...
    Java:- go.telusko.com...
    Java Spring:- go.telusko.com...
    Java For Programmers:- go.telusko.com...
    Python : go.telusko.com...
    Git : go.telusko.com...
    Docker : go.telusko.com...
    For More Queries WhatsApp or Call on : +919008963671
    website : courses.telusk...
    Instagram : / navinreddyofficial
    Linkedin : / navinreddy20
    TELUSKO Android App : bit.ly/TeluskoApp
    In this lecture we will learn:
    What are Bitwise operators in Python?
    Different types of bitwise operators
    How operations performed on bits
    Implementation of bitwise operations
    #1
    In bitwise operations, the integers are first converted into binary and then operations are performed by bitwise operators on each bit or corresponding pair of bits.
    The result is returned in decimal format by the bitwise operators.
    There are six types of binary operators:-
    1. Complement (~)
    2. And (&)
    3. Or (|)
    4. XOR (^)
    5. Left Shift
    6. Right Shift
    #2
    Complement operator is also known as tilde(~) operator.
    Complement simply do the reverse of binary form. If a bit is 0 then it makes it 1 and vice-versa.
    Reverse of each bit of a number returns the 1's complement.
    We can store only positive numbers in our system and that's why we find the 2's complement of each negative number.
    2's complement = 1's complement +1
    #3
    -AND operator will return true if both the conditions are true while the OR operator will return true if at least one condition is true.
    #4
    XOR operator will return 1 or true when there is an odd number of 1 bit present in operations and if there is an even number of 1, then it will return 0.
    #5
    Leftshift operator shift bits on the left-hand side. The right-shift operator shifts bits on the right-hand side.
    Leftshift add the bits while the right-side removes the bits.
    Github :- github.com/nav...
    Python for Beginners :- bit.ly/3JOLQhl
    Java:- bit.ly/JavaUde...
    Spring:- bit.ly/SpringU...
    More Learning :
    Java :- bit.ly/3x6rr0N
    Python :- bit.ly/3GRc7JX
    Django :- bit.ly/3MmoJK6
    JavaScript :- bit.ly/3tiAlHo
    Node JS :- bit.ly/3GT4liq
    Rest Api :-bit.ly/3MjhZwt
    Servlet :- bit.ly/3Q7eA7k
    Spring Framework :- bit.ly/3xi7buh
    Design Patterns in Java :- bit.ly/3MocXiq
    Docker :- bit.ly/3xjWzLA
    Blockchain Tutorial :- bit.ly/3NSbOkc
    Corda Tutorial:- bit.ly/3thbUKa
    Hyperledger Fabric :- bit.ly/38RZCRB
    NoSQL Tutorial :- bit.ly/3aJpRuc
    Mysql Tutorial :- bit.ly/3thpr4L
    Data Structures using Java :- bit.ly/3MuJa7S
    Git Tutorial :- bit.ly/3NXyCPu
    Donation:
    PayPal Id : navinreddy20
    www.telusko.com
  • Наука та технологія

КОМЕНТАРІ • 1,4 тис.