English
Tamil Nadu Board of Secondary EducationHSC Science Class 11

What is the error in the following structure definition. struct employee{ inteno;charename[20];char dept;} Employee e1,e2; - Computer Science

Advertisements
Advertisements

Question

What is the error in the following structure definition.
struct employee{ inteno;charename[20];char dept;} Employee e1,e2;

Short Note

Solution

Errors:

  1. ‘i’ is missing.
  2. Spaces are missing at two places
  3. The structure name was given wrongly.

Corrected structure:

struct employee {int eno; char ename [20]; char dept;}
employee e, e2;

shaalaa.com
Structures Introduction
  Is there an error in this question or solution?
Chapter 12: Arrays and Structures - Evaluation - Section - B [Page 224]

APPEARS IN

Samacheer Kalvi Computer Science [English] Class 11 TN Board
Chapter 12 Arrays and Structures
Evaluation - Section - B | Q 5. | Page 224
Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×