UrbanPro

Learn C Language from the Best Tutors

  • Affordable fees
  • 1-1 or Group class
  • Flexible Timings
  • Verified Tutors

Search in

how the right shift operator works on a numerical value?? eg:- 8>>3=?

Asked by Last Modified  

Follow 0
Answer

Please enter your answer

SUDHIR SHARMA - Computer Trainer based On Hyderabad

Binary of 8 is "1000" and here by this command 3 bits of "1000" will be shifted to right. Hence Binary will be "0001" so your expressions answer will be "0001" i.e. 1
Comments

Enthusiastic Learner and Teacher

8 in binary is 1000 You're shifting it by 3 times After first shift 0100 After second shift 0010 After Third shift 0001 So you'll be left with 8>>3=1 To make it simple, every time you shift right your number gets divided by 2 and every time you shift left your number gets multiplied by 2.
Comments

first convert numerical value to binary value then arrange into bits and shift 3 bit on right then convert binary value to decimal value.
Comments

C++, Data Structures, Software Engineering working professional.

This is bitwise operator, forget about the numeric value, You will have to think in terms of sequence of bits, Just write down these two numbers in bits, and start moving the bits,
Comments

Expert Technical Trainer with 15 years of work experience

The decimal value need to converted to equivalent binary values and then shift right operation is performed
Comments

After converting the numerical value into binary value right shift operator starts its working.
Comments

Computer and Photography Instructor

its a Shift operator and its shifted 3 times in right onwards. all in bit wise. (1000)2 in binary form. after shifting 3 position on rightwords the value is (0001)2 in Decimal value is 1
Comments

MCA

This operator shifts the first operand the specified number of bits to the right. Excess bits shifted off to the right are discarded. Copies of the leftmost bit are shifted in from the left
Comments

Master of Computer Applications (M.C.A)

In C right shift works like this .... it divides the 8 by the 2 power of 3...
Comments

Computer Wizard

It's right shift bitwise operator 1) data shifted by specificed number of position to right. 2)when data shifted right ,leading zero's are filled with zero .and it's binary operator ( means it require two argument s)
Comments

View 16 more Answers

Related Questions

Is C destined to die?
No not at all
Anubhav
0 0
5
What is the structure of a C program?
A basic structure of a C program typically consists of: 1. **Preprocessor Directives:** These are lines of code that begin with a `#` symbol. They are instructions to the compiler to include certain...
Snehal
0 0
5
How would you round off a value from 1.66 to 2.0?
By adding 1.0 (float) to the integer part (type casted) of 1.66.
Dhanya
0 0
6
What does # mean in C?
#include is a preprocessor directive which is used to include user-defined file.
Sridevi
0 0
5
How do you sort filenames in a directory?
The idiomatic way to sort something in C is to use the qsort() function. For this to work, it's best if you can arrange to have all the file names collected into an array of pointers, and then you sort...
Ajay
0 0
9

Now ask question in any of the 1000+ Categories, and get Answers from Tutors and Trainers on UrbanPro.com

Ask a Question

Related Lessons

What Would Be Life Cycle Of A Fresher After Campus In An IT Company?
1. Basic Technical Training: Since freshers are not subject matter experts so gone through 3 - 6 months basic technical training within Organization. 2. Technical Assessment: HR sends freshers to various...

Basics Of C And C++
C++ is powerful, highly flexible, and adaptable programming language that allows software engineers to organise and process information quickly and effectively. But this high-level language is relatively...

Difference Between C Language and C Program
C Language: C Language is structured, high level and machine independent language. C Program: C Program is the collection of functions that are supported by C library.
S

Shashwat Kumar

0 0
0

Bit wise operators in C
Bit Wise Operators Bit Wise operators are manipulates of individual bits with in a word of memory. The bit wise operators can be divided in to three general category. One’s Complement...

4 Things Every Tech Startup Needs to Know About The Coaching Industry
Knowledge on any subject is widely available to those who wish to learn. However, just gathering knowledge from other people doesn’t guarantee results in business. Results come from applying what...

Recommended Articles

Lasya Infotech is a Hyderabad based IT training institute founded in 2016 by O Venkat. Believing in his innovation, passion and persistence and with a diverse blend of experience, he started his brainchild to deliver exemplary professional courses to aspiring candidates by honing their skills. Ever since the institute envisions...

Read full article >

Brilliant Academy is one of the reputed institutes for B.Tech tuition classes. This institute is specialised in delivering quality tuition classes for B.E, Engineering - all streams and Engineering diploma courses. Incorporated in 2012, Brillant Academy is a brainchild of Mr Jagadeesh. The main motto of the academy is to...

Read full article >

Business Process outsourcing (BPO) services can be considered as a kind of outsourcing which involves subletting of specific functions associated with any business to a third party service provider. BPO is usually administered as a cost-saving procedure for functions which an organization needs but does not rely upon to...

Read full article >

Microsoft Excel is an electronic spreadsheet tool which is commonly used for financial and statistical data processing. It has been developed by Microsoft and forms a major component of the widely used Microsoft Office. From individual users to the top IT companies, Excel is used worldwide. Excel is one of the most important...

Read full article >

Looking for C Language Classes?

Learn from the Best Tutors on UrbanPro

Are you a Tutor or Training Institute?

Join UrbanPro Today to find students near you
X

Looking for C Language Classes?

The best tutors for C Language Classes are on UrbanPro

  • Select the best Tutor
  • Book & Attend a Free Demo
  • Pay and start Learning

Learn C Language with the Best Tutors

The best Tutors for C Language Classes are on UrbanPro

This website uses cookies

We use cookies to improve user experience. Choose what cookies you allow us to use. You can read more about our Cookie Policy in our Privacy Policy

Accept All
Decline All

UrbanPro.com is India's largest network of most trusted tutors and institutes. Over 55 lakh students rely on UrbanPro.com, to fulfill their learning requirements across 1,000+ categories. Using UrbanPro.com, parents, and students can compare multiple Tutors and Institutes and choose the one that best suits their requirements. More than 7.5 lakh verified Tutors and Institutes are helping millions of students every day and growing their tutoring business on UrbanPro.com. Whether you are looking for a tutor to learn mathematics, a German language trainer to brush up your German language skills or an institute to upgrade your IT skills, we have got the best selection of Tutors and Training Institutes for you. Read more