Structures

  1. Which of the following structure declaration is correct ?
    1. struct employ
      {
      char name[10];
      float salary;
      int workingdays;
      };
    2. struct employ
      {
      char name[10];
      float salary;
      int workingdays;
      }
    3. struct employ
      {
      char name[10]
      float salary
      int workingdays
      };
    4. All of the above.
  1. View Hint | View Answer | Workspace | Discuss In Forum | Report

    In B semicolon is missing after the declaration. In C semicolon is missing after each structure element.

    Correct Option: A

    In B semicolon is missing after the declaration. In C semicolon is missing after each structure element.

    Report