Why whole structure can not be compared in C yet it can be copied? In other words, Why comparison in below program does not work? It does not print string.
#include <stdio.h>
#include <string.h>
int main(void)
{
struct emp
{
char n[20];
int age;
};
struct emp e1={"David",23};
struct emp e2=e1;
if(e2 == e1)
{
printf("The structures are equal");
}
return(0);
}