How to write a program to modify a word using a bit mask ?

#include <stdio.h> int main() { typedef int bool; bool f; /* conditional flag */ unsigned int m; /* the bit mask */ unsigned int w; /* the word to modify: if (f) w |= m; else w &= ~m; */ printf(“Enter the word to modify “); scanf(“%u”,&w); printf(“Enter the bit mask “); scanf(“%u”,&m); /* w …