Memory constrained embedded systems, IoT devices cannot have liberty to use lots of
memory. You are tasked to store the result of a NUCES-FAST student in one single variable. This can
be done using all bits of that variable in an efficient way. Write a program which prompts user to enter
the following student data and convert all this information to store in a single variable (see sample run).
Use bitwise AND, OR and SHIFT operators. Also use if-else where needed. (20 marks)
Here is program:
Here is program:
int main() {
  int NUCESFAST = 7;
  int* b = &NUCESFAST;
  cout << &NUCESFAST;
}
Comments
Leave a comment