can we define a function in structure?

Answer Posted / anandhi

structure is nothing but user defined data types...
structure used then more then one datatypes used in single
strud\cture...
syntax:
struct [struct_name]
{
datatype var1;
...
...
};
struct variable creation:
syntax:
struct [name]
{
...
...
}[struct var_name];
[struct var_name].variablename;
.......................................
ex:

Is This Answer Correct ?    0 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain what are the different data types in c?

980


1234554321 1234 4321 123 321 12 21 1 1 12 21 123 321 1234 4321 1234554321

3465


the process of defining something in terms of itself is called (or) in C it is possible for the functions to call themselves. A function called a) nested function b) void function c) recursive function d) indifinite function

1057


Explain what is meant by 'bit masking'?

908


Can we change the value of constant variable in c?

843


what are the facialities provided by you after the selection of the student.

1957


What are structures and unions? State differencves between them.

880


What are c identifiers?

873


What is the difference between the = symbol and == symbol?

853


Why do we use c for the speed of light?

843


If jack lies on Mon, Tue Wed and jill lies on Thursday, Friday and Saturday. If both together tell they lied yesterday. So c the given options and then c cos in the given dates one will be saying the truth and one will be lying. I got Thursday as option because jack is saying the truth he lied yest but jill is lying again as he lies on that day.

2030


What is a nested formula?

833


Differentiate abs() function from fabs() function.

817


What is operator precedence?

924


Differentiate between the = symbol and == symbol?

957