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));

UN KNOWN STORY BETWEEN TESLA AND EDISON

  Onceupon a time was a Austiria -American scientist named NIKOLAS TESLA . In fact he was not a scientist , but mathematecian . He was desired to work with the great scientist Thomas Alva Edison, but successfully his dream came to fullfill on 1884. At first Edison treated Tesla very bad like, not considering his ideas even though it was good . At last a challenge came infront of Tesla, i.e Edison made an agreement with Tesla that if he find AC current then he will give what ever Tesla need . 
     
            Taking it as a challenge Tesla spend all his time in finding AC current at last, Edison find AC current . One day during the time of experiment Tesla unexpectedly found DC  current . 


             Before finding DC Current  all over the world people's are using AC current. After discovering DC current Tesla made aggrement with a private company and became a competitor for Edison . As AC current has a disadvantage like building of power distribution centre for each locality , but where as in case of DC current there is no need of any seperate power distribution centre and it is cheaper than AC current. 



          By this the profits of Edison company fell down . By then he think cunningly and blamed that usage of DC current is dangerous by conducting an experiment i.e passing DC current to hen and proved that if it goes inside our body then we will die . After knowing that Edison used to oppose that his ideas dangerous then Tesla made to pass the DC current into his body infront of all the people including Edison and concluded that it is not dangerous . 

  
         After that he taught to supply current to every one through air , and there is no any intermediate stations . Before completing it he was died . I think if he implemented it then there will be no current charges we have to pay .

           This was the mystery in between Edison and Tesla..........
           
           Thank you for watching

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 || 🔥🔥🔥💯💯💯✅✅✅