Write a function that accepts two numbers,say a and b and
makes bth bit of a to 0.No other bits of a should get
changed.
Answers were Sorted based on User's Feedback
Answer / sandeep ambekar
Macro to Set a particular Bit..
#define SetBit(x,y) x | 0x1<<y
Macro to Clear a particular Bit..
#define ClearBit(x,y) x & ~(0x1<<y)
| Is This Answer Correct ? | 5 Yes | 2 No |
Answer / ramkumar
int func(int a,int b)
{
int ans;
ans = a - 2^b;
return ans;
}
| Is This Answer Correct ? | 0 Yes | 7 No |
write a c program to add two integer numbers without using arithmetic operator +
Finding first/last occurrence of a character in a string without using strchr( ) /strrchr( ) function.
what is the use of ~ in c lang?????
which is an algorithm for sorting in a growing Lexicographic order
write a c program that prints all multiples of 3between 1 and 50.
main() { int x=5; printf("%d %d %d\n",x,x<<2,x>>2); } what is the output?
send me the code of flow chart generator using C-programming language amd this code should calculate the time and space complexity of the given progran and able to generate flowchart according to the given program?
write c program without semicolon
11 Answers MindTech, TCS, Wipro,
What is the use of pragma in embedded c?
How many ways are there to swap two numbers without using temporary variable? Give the each logic.
main() { int i=1; while (i<=5) { printf("%d",i); if (i>2) goto here; i++; } } fun() { here: printf("PP"); }
write a progam to display the factors of a given number and disply how many prime numbers are there?