Generation

generate functionSat, 16 Mar 2024

Write a program to exchange the contents of data segment memory locations (DS:130H ,DS: 131H) and (DS:13AH,DS:13BH)

id swap(unsigned char *a, unsigned char *b) { unsigned char temp; temp = *a; *a = *b; *b = temp; } int main() { unsigned char a = 1; unsigned char b = 2; swap(&a, &b); printf("%d\n", a); printf("%d\n", b); return 0;

Questions about programming?Chat with your personal AI assistant