what is the main difference between c and c++?
Answer Posted / md.mohibullah
1.In c++,I/O is performed using I/O operators instead of I/O
functions.
2.In c,when a function takes no parameters,its prototype has
the word void inside its function parameter list.But,in
c++,the void is optional.
for instance,char f1(void)[in c]
char f1()[in c++]
3.In c++,local variables can be declared anywhere but in
c,local variables can be declared only at the start of a block.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is constructor in oop?
class CTest { public: void someMethod() { int nCount = 0; cout << "This is some method --> " << nCount; } }; int main() { CTest *pctest; pctest->someMethod(); return 0; } It will executes the someMethod() and displays the value too. how is it possible with our creating memory for the class . i think iam not creating object for the class. Thanks in Advance... Prakash
What is persistence in oop?
Can a destructor be called directly?
What is object in oop with example?
Why do we use class in oops?
What is the problem with multiple inheritance?
What is multilevel inheritance explain with example?
What is inheritance write a program to show use of inheritance?
What does and I oop mean in text?
write a code for this. serial_number contained in the header of the file will be read , if this serial number is less than a previous serial number within a successfully processed file, or is the same as another serial number within a successfully processed file, or if the field contains anything other than 7 digits, then the file must error with the reason ‘Invalid SERIAL_NUMBER’.
what type of question are asked in thoughtworks pair programming round ?
Can we have inheritance without polymorphism?
What is a class in oop?
can inline function declare in private part of class?