Question

Canvas → X COB D Question 12 Consider the following structure definition and variable declaration written in C. struct depart

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Answer 12:
CSdept.num_employees=50;
CSdept.name="CS";

// we use . operator to access the variables inside the structure
Note : Please comment below if you have concerns. I am here to help you
If you like my answer please rate and help me it is very Imp for me

Add a comment
Know the answer?
Add Answer to:
Canvas → X COB D Question 12 Consider the following structure definition and variable declaration written...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Canvas → XC D Question 13 Given the code below: typedef struct p { char topic...

    Canvas → XC D Question 13 Given the code below: typedef struct p { char topic [20]; int nunWords; > page; typedef struct mag char name[20]; page pages [250); int numPages; } magazine; magazine m; How would you declare an array of 20 magazines? struct magazine[20] magazine[20] magazine myStack(20) None of the above struct m[191 Question 14 Given the code below: typedef struct char topic[20] Canvas & XC struct m[19] Question 14 Given the code below: typedef struct char topic[20];...

  • in C language we need to find the following : EXERCISE 3: 1. Write the definition...

    in C language we need to find the following : EXERCISE 3: 1. Write the definition of a structure named employee that contains character array members for an employee's first and last names, an int member for the employee's age, a char member that contains 'M' or 'F' for the employee's gender, and a double member for the employee's hourly salary. 2. Using the above mentioned definition, write a C program that asks a user to enter the values of...

  • C programming The program will require the following structure: struct _data { char *name; long number;...

    C programming The program will require the following structure: struct _data { char *name; long number; }; The program will require command line arguments: int main(int argv, char **argc) { Where argv is the number of arguments and argc is an array holding the arguments (each is a string). Your program must catch any case where no command line arguement was provided and print a warning message (see below). You MUST include/use the following functions, defined as follows: int SCAN(FILE...

  • please help Write a simple program with Student class having STL list of Record's structure as...

    please help Write a simple program with Student class having STL list of Record's structure as a member. 1. Records of the Students are not accessible to the outside world. 2. Student shall output its standing (Freshman, Sophomore etc). 3. A Student can only be created with the name 4. A class can only be added if there is a class name and the passing grade. Driver program creates a Student, adds few classes to the Student's records, then prints...

  • QUESTION 25 Examine the following program segment. Assuming the array table has values in it, what...

    QUESTION 25 Examine the following program segment. Assuming the array table has values in it, what is the correct outcome? double table [10] [2], sum=0.0; int i, j, nrows=10; for(i=0; i<=nrows-1; i++) sum += tableta (3); It will sum the table values in the rows only. It will sum the table values in the columns only. It will not sum the table values because nrows is too small. It will not sum the table values because the columns are not...

  • QUESTION 1 Using the following declarations and a member of the Array class, int [ ]...

    QUESTION 1 Using the following declarations and a member of the Array class, int [ ] bArray = new int [10]; int location; Using a method in the Array class, write a statement that would change the order of the elements in the bArray array. The contents of the first cell should hold what was in the last cell. The second cell should hold what was in the next to last cell. __________________________ HINT: You must write the full statement...

  • I need help on this Systems review please! it's due by midnight monday. Question 1 Not...

    I need help on this Systems review please! it's due by midnight monday. Question 1 Not yet answered Points out of 1.00 Flag question Question text Using these declarations: int * numberPointers[3]; int * pointer; int number; Which of the following statements would generate a warning or error? Select one: a. number = pointer; b. *pointer = number; c. pointer = numberPointers; d. numberPointers[2] = &number; e. a., b., and d. f. a. and c. Question 2 Not yet answered...

  • Please explain answer :D Question 5 (5 marks] Consider the syntactically correct C code below, which...

    Please explain answer :D Question 5 (5 marks] Consider the syntactically correct C code below, which is missing a function print_diagonal include <stdio.h> • typedef int Table(100) (100); */• print diagonal (T, n) . Given a Table T, which will have n rows and n columns, print all of the 1 entries on the main diagonal of T (that is, entries whose row number and column number are equal). Remember to print a newline at the end. / ► /...

  • 1. Define Structure UNIT as described in the list: ınit char codease complete the question int...

    1. Define Structure UNIT as described in the list: ınit char codease complete the question int numberOfCreditHours int semester int numberOfPreReq; pointer to number of pre-requisites eg:like char preRequisite[numberOfPreReq][10]; char* preReq int numberOfPostReq; pointer to number of post-requisites eg:like char postRequisite[numberOfPostReq] [1 0]; char* postReq NOTE: this is a BIG question and has to be asked seperately, answering only one question here. pluginfile.php/94428/mod resource/content/1/lab 6202 %20 %28file %20and%20parsing % 29.pdf Expected C++Skills to finish this activity Simple data types C++...

  • Question 1 What is the value of x after the following int x = 5; x++;...

    Question 1 What is the value of x after the following int x = 5; x++; x++; x+=x++; A)14 B)10 C)13 D)15 Question 2 The last line in value returning function (before the }) should contain the word return. True False Question 3 This contains three parts: Void or Data Type the name optional parameter list A)Menu System B)Function Header C)Switch Question 4 What is a variable? A)a pointer B)a place in memory to hold data C)int D)a computer programming...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT