19 lines
425 B
C
19 lines
425 B
C
#include <string.h>
|
|
#include <stdio.h>
|
|
|
|
typedef struct {
|
|
char areaCode[10];
|
|
char exchangeCode[40];
|
|
} PhoneNumber;
|
|
|
|
int main() {
|
|
PhoneNumber a, b;
|
|
scanf("%s %s", a.areaCode, a.exchangeCode);
|
|
scanf("%s %s", b.areaCode, b.exchangeCode);
|
|
if (strcmp(a.areaCode, b.areaCode) == 0) {
|
|
printf("%s", b.exchangeCode);
|
|
} else {
|
|
printf("%s%s", b.areaCode, b.exchangeCode);
|
|
}
|
|
return 0;
|
|
} |