c program to clear nth bit of the number || Bitwise Operators || Problem Solving ||

#include <stdio.h> int main() {     int num, n, newNum;     printf("Enter any number: ");     scanf("%d", &num);     printf("Enter nth bit to clear (0-31): ");     scanf("%d", &n);     newNum = num & (~(1 << n));     printf("Number before clearing %d bit: %d (in decimal)\n", n, num);     printf("Number after clearing %d bit: %d (in decimal)\n", n, newNum);     return 0; } Logic :-  num&(~(1<<n));

Typing Lesson PART-2


Lesson-2
   


NOTE : You need to type the letter 'g' with left hand index finger. Same way you type 'h' with right hand index finger.


asdfgf ;lkjhj asdfgf ;lkjhj asdfgf ;lkjhj 
asdfgf ;lkjhj asdfgf ;lkjhj asdfgf ;lkjhj 
asdfgf ;lkjhj asdfgf ;lkjhj asdfgf ;lkjhj 
asdfgf ;lkjhj asdfgf ;lkjhj asdfgf ;lkjhj 
Type this lesson for 2 days. Untill you get perfection on this lesson.

Important  words for the above lesson:

all                  salad.         add           lak
gag                shall.          lash.          hash
glad               sal.             half.           glass
lags.              ass.             dhald.       ash
algal.             dad.           falls.          ask
fag.                shah.          hag.          jakal
kad.               shad.          jag.           alas
flag                slash.         falls
dash.             kalsa.        flags
    

Comments

Popular posts from this blog

Merge Strings Alternatively || Leetcode Solution || Easy Approach || Simple || ✅✅✅✅💯💯💯💯🔥🔥🔥🔥

HOW TO PREPARE FOR JEE MAINS IN HOME EFFECTIVELY

1978. Employees Whose Manager Left the Company || Leetcode SQL solution || simple sql query || 🔥🔥🔥💯💯💯✅✅✅