What normal C constructs work differently in C++?
Answers were Sorted based on User's Feedback
Answer / guest
- Assigning int's to enum's.
- Assigning void pointers to other types of pointers.
- Function declaration foo() without parameters.
- Character constants are of type char in C++. They are of
type int in C.
- ALL functions MUST be prototyped in C++, which is not
required in C.
- In C++:
struct A { /* ... */ };
is equivalent to:
typedef struct A { /* ... */ } A;
in C.
| Is This Answer Correct ? | 2 Yes | 0 No |
Answer / achal ubbott
I just add 2 more points. C++ is a different language. Its
syntax matches to C accidentally.
1. C++ follows a name mangling algorithm for names of
functions. C does not.
2. C++ structures may have functions defined in them. Not
in C.
3. C++ follows more strict type checking.
| Is This Answer Correct ? | 0 Yes | 0 No |
OOP'S advantages of inheritance include:
What is multilevel inheritance in oop?
what are three tenets of object orinted Systems?Why they call like that ? Please answer me. Advance thanks.
C#.net Interview Question A=10 B=5 C=A+B Print C The above will be given in a multiline textbox. You need to parse the above input, store values for A,B&c. And you have to display the value of C.
Get me a number puzzle game-program
How to improve object oriented design skills?
Describe what an Interface is and how it?s different from a Class.
What is encapsulation?
Write pseudo code for push in a stack?
how do u initialize the constant variables
What is polymorphism and its types?
i ahve v low % in 12th n BSC which is aroun 50 coz science was imposed on me......nw m doin MCA n my aggregate in above 74%,what shud i say if asked about low previous percentage??????