Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


which is the easy way to divide any integer by 2?

Answers were Sorted based on User's Feedback



which is the easy way to divide any integer by 2?..

Answer / rahul

int i = 10;
i = i >> 1;

Is This Answer Correct ?    15 Yes 0 No

which is the easy way to divide any integer by 2?..

Answer / saranya

if s=10
s=s>>1

Is This Answer Correct ?    5 Yes 1 No

Post New Answer

More C++ General Interview Questions

What is scope of a variable? (LOLZ)

2 Answers   CA, TCS,


class A { public: void f(); protected: A() {} A(const A&){} }; Examine the class declaration shown above. Why are the default and copy constructors declared as protected? 1. To ensure that A cannot be created via new by a more derived class 2. To ensure that A cannot be copied 3. To ensure that A cannot be used as a base class except when public inheritance has been used 4. To ensure that A cannot be created/copied outside the inheritance chain 5. To ensure that A cannot be instantiated as a static variable

1 Answers  


Give a very good method to count the number of ones in a "n" (e.g. 32) bit number.

3 Answers  


True or false, if you keep incrementing a variable, it will become negative a) True b) False c) It depends

0 Answers  


How to create a reference variable in C++

1 Answers  


What is abstraction with real time example?

0 Answers  


write a program in c++ to generate imp z y x w v w x y z z y x w x y z z y x y z z y z z

4 Answers  


What is long in c++?

0 Answers  


What is "strstream" ?

1 Answers   Huawei,


Difference between Abstraction and encapsulation in C++?

0 Answers   Impetus,


What is rvalue?

0 Answers  


Why pure virtual functions are used if they don't have implementation / When does a pure virtual function become useful?

1 Answers  


Categories