The following table shows some similarities and differences in features and the use of terms and concepts in Smalltalk, C++, and Java. OO Concept/syntax Smalltalk C++ Java Abstract class Concept exists, no mechanism for enforcement A class with a pure virtual function can’t be instantiated Classes may be declared abstract Assignment operator := = = [...]
Archive for the ‘C’ Category
OOPL Comparison Leave a comment
Differences Between C and Java Leave a comment
If you are a C or C++ programmer, you should have found much of the syntax of Java–particularly at the level of operators and statements–to be familiar. Because Java and C are so similar in some ways, it is important for C and C++ programmers to understand where the similarities end. There are a number [...]
Differences Between Java and C/C++ Leave a comment
The Preprocessor Pointers Structures and Unions Functions Multiple Inheritance Strings The goto Statement Operator Overloading Automatic Coercions Variable Arguments Command-Line Arguments It is no secret that the Java language is highly derived from the C and C++ languages. Because C++ is currently considered the language of choice for professional software developers, it’s important to understand [...]
Arrays Leave a comment
In this section, we will create a small C program that generates 10 random numbers and sorts them. To do that, we will use a new variable arrangement called an array. An array lets you declare and work with a collection of values of the same type. For example, you might want to create a [...]
Memory Leak in C Program Leave a comment
Why do we need to test weather it is memory leak or not? How are we going to know that?Possibilities are: 1) Array will print “Garbage Value” 2) Message by the Compiler! Because size of heap memory will be reduced and leaked memory can not be assigned to other processes running simultaneously in a multiprogramming [...]