Difference between Java and C

September 10th, 2006 Admin Posted in Difference between Java and C No Comments »

Difference between Java and C

  • Java does not include the C unique statement keywords goto, sizeof and typedef.
  • Java does not contain the data types struct, union and enum.
  • Java does not define the type modifiers keywords auto,extern,register,signed and unsigned.
  • Java does not support an explicit pointer type.
  • Java does not have a preprocessor and therefore we cannot ude #define, #include and #ifdef statements.
  • Java does not support any mechanism for defining variable arguments to functions.
  • Java requires that the functions with no arguments must be declared with empty parenthesis and not with the voide keyword as done in C.
  • Java adds new operators such as instanceof and >>>.
  • Java adds labelled break and continue statements.
  • Java adds many features required for object-oriented programming.
AddThis Social Bookmark Button