B, plants and weather are part pf nature.
Answer:
Explanation:
Two ways of interpreting this question
(I) Shifting all the bits along with the choosen four,
in that case it will be i1>>2;
(ii) Just shifting the choosen four bits and keeping the remaining as it is.
It is equivalent to replacing the first four bits of i1 with i1>>2. let us call N = i1, and M = i1>>2.
max = ~0 //All one's
//1's through position 4, then all zeros
left = max - ((1<<4) - 1);
So we just have zeros between bits one to four and other are one.
Now final step;
(N&left) | m
Answer:
Following are the program in c++ language
#include <iostream> // header file
using namespace std;// namespace
int main() // main function
{
int num; // variable declaration
long int f=1; // variable declaration
do
{
cout<<"Enter the Positive value:";
cin>>num;
} while(num<0); // i check whether number is non negative or not
while(num>0) // iterating over the loop
{
f=f*num; // calculate the factorial
num--; // decrement the value of num by 1
}
cout<<" factorial is :"<<f; // display the factorial .
return 0;
}
Output:
Enter the Positive value:7
factorial is :5040
Explanation:
Following are the description of the program .
- Read the input by user in the "num" variable of "int" type..
- The do-while will check the enter number is nonnegative number.
- While(n>0) loop is calculating the factorial in the "f" variable .
- Finally display the factorial .
Answer:
Move closer to the wireless access point
Explanation: