a5: Programm fertig
This commit is contained in:
parent
d14a041061
commit
ac56259ce8
@ -44,7 +44,6 @@ int main(int argc, char **argv) {
|
||||
int flagArray[12];
|
||||
|
||||
|
||||
|
||||
for(int i = 0; i < 12; ++i) {
|
||||
flagArray[i] = *flags % 2;
|
||||
*flags = *flags / 2;
|
||||
@ -54,17 +53,25 @@ int main(int argc, char **argv) {
|
||||
printf("%d ", flagArray[i-1]);
|
||||
}
|
||||
|
||||
|
||||
|
||||
printf("\n\n");
|
||||
|
||||
printf("Ergebnis und Operanden Signed:\n");
|
||||
printf("%d %c %d = %d", sop1, what, sop2, signedRes);
|
||||
printf("%d %c %d = %d\t", sop1, what, sop2, signedRes);
|
||||
if(flagArray[11] != 0)
|
||||
printf("Ergebnis ist falsch!");
|
||||
else
|
||||
printf("Ergebnis ist richtig!");
|
||||
|
||||
|
||||
printf("\n\n");
|
||||
|
||||
printf("Ergebnis und Operanden Unsigned:\n");
|
||||
printf("%u %c %u = %u", uop1, what, uop2, unsignedRes);
|
||||
printf("%u %c %u = %u\t", uop1, what, uop2, unsignedRes);
|
||||
|
||||
if(flagArray[0] != 0)
|
||||
printf("Ergebnis ist falsch!");
|
||||
else
|
||||
printf("Ergebnis ist richtig!");
|
||||
|
||||
printf("\n\n");
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user