1. Write the ARM code of the following fragment of C code:
Switch(i) {
case 0: a=b+c; break;
case 1: a=b-c; break;
case 2: a=b*c; break;
case 3: a=b/c; break;
}
The input is i, the output is a. You need to initialize the variables b, and c respectively.
Switch(i) {
case 0: a=b+c; break;
case 1: a=b-c; break;
case 2: a=b*c; break;
case 3: a=b/c; break;
}
The input is i, the output is a. You need to initialize the variables b, and c respectively.
Comment