What is the difference between objected oriented language(like java) and procedural language(like c)?and which one is better??
Home/
Engineering Questions/Language
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
sonali patnaik
The focus of procedural programming is to break down a programming task into a collection of variables, data structures, and subroutines, whereas in object-oriented programming it is to break down a programming task into objects with each “object” encapsulating its own data and methods (subroutines). The most important distinction is whereas procedural programming uses procedures to operate on data structures, object-oriented programming bundles the two together so an “object” operates on its “own” data structure.
so i feel object oriented language is better..
palakpuja
-C uses concept of structures (not object oriented).
-In C we use the concept of pointers whereas there are no pointers used in JAVA
-In C the programmer needs to manage memory manually. “malloc()” and “free()” are the fundamental memory allocation library calls.
-In C the declaration of variables should be on the beginning of the block.
-C supports go to statement, struct and union unlike Java
-C is compiled to the machines “native language” so it’s execution is much faster than Java’s.
-No reuse in code and by default members are public.
-C programs will have a larger memory footprint than an equivalent program written in pure machine code, but the total memory use of a C program is much smaller than the a Java program because C does not require the loading of an execution interpreter like the JVM.
-The main differences between Java and C are speed, portability, and object-orientation.