Question: c language question one image contains code while the other contain options. typedef struct t_emp { char firstName[ 20 ]; char lastName [ 20 ];
![options. typedef struct t_emp { char firstName[ 20 ]; char lastName [](https://dsd5zvtm8ll6.cloudfront.net/si.experts.images/questions/2024/09/66f541dc70ccc_21266f541dc0f173.jpg)
typedef struct t_emp { char firstName[ 20 ]; char lastName [ 20 ]; unsigned int age; char gender; double hourlysalary; }Employee; // structure definition For the above structure definition and the following declarations: Employee emp [10] : Employee ptr = emp: following code correctly assigns 'lastName of the second element of the array, Employee emp [10] ; Employee* ptr = emp; following code correctly assigns 'lastName' of the second element of the array. strncpy(lastName[1], "John"); Optr++; ptr->strcpy(lastName, "John"); strcpy(ptr->lastName, "Baptist"); ptr++; strcpy(ptr->lastName, "Baptist"); None of these
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
