BigEdu.ru
» » » Differences Between Java And C Essay Research
Вернуться назад

Differences Between Java And C Essay Research

Differences Between Java And C++ Essay, Research Paper

DIFFERENCES BETWEEN JAVA AND C++1 INTRODUCTION Since its release in 1995, Java has been hyped in many places, including computer magazines, broadcast news, and the Internet, as the solution to all problems in the application development community. As it has only been around for approximately 4 years now, it is still emerging into the programming language market. The main area where Java has had a large impact had been on the Internet. It is widely maintained that “Java is definitely the best tool so far for writing Internet applets.” (http://www.relisoft.com/java/c_java.html) Testimony to this statement are the numerous sites on the WWW that currently use java applets.Apart from being able to create “cute” Internet applets, as yet Java has struggled to break into the area of application development. When compared to a language such as C++, java has some large advantages but also some disadvantages. In this paper I plan to discuss the differences between these languages and the merits of each.2 ADVANTAGES OF JAVA One of the attractions of Java as a programming language is that is is a purely object oriented language. This allows programmers to design reusable components easily, which can reduce development time. “You can churn out Java four or five times faster than C++” (http://www.mcmillan.com/JavaVs.htm) Another factor that can help reduce development time is its relatively simple syntax. It’s very similar to C++, making it very easy for an experienced C++ programmer to learn Java. Also it’s automatic memory management, which includes a garbage collector, negates the need to keep track of pointers or delete objects. This makes it much simpler to write and understand than C++. Another advantage Java has over other languages is its portability. When a Java program is compiled, it is not compiled into native machine code, instead it is compiled into byte code which can be interpreted by a Java Virtual Machine running on the host computer. Once a specific computer architecture has a Virtual Machine designed for it, the computer can execute any Java program that has been compiled into byte code. This portability becomes evident in web based applications. Web developers can write applications in Java, compile them once, and run them on any machine that has a Java compatible web browser. Although Java’s portability gives it a clear advantage over other languages, this feature also creates one of Java’s biggest disadvantages. 3 DISADVANTAGES OF JAVA Although Java’s ability for producing portable, architecturally neutral code is desirable, the method used to create this code is inefficient. Unlike natively compiled code, an interpreter must first translate the Java binary code into the equivalent microprocessor instruction. Obviously, this translation takes some amount of time and, no matter how small a length of time this is, it is slower than performing the same operation in machine code. On occasions where it is desirable for code to be as efficient as possible, Java’s automatic memory management may not be the best option. In languages such as C++ where memory management is done explicitly, it may be possible to speed up a program by altering the memory allocation and deletion, but this ability is taken away from us in Java. 4 DIFFERENCES BETWEEN JAVA AND C++ 4.1 Theoretical Differences4.1.1 Speed DifferencesThe difference in speed between C++ and Java is very important. Even with all of Java’s benefits, Java will not be widely excepted if it can not perform adequately. C++ has been widely adopted by developers and they will not be willing to change languages if the applications they develop with Java do not measure up to their personal and their clients standards. However, if the speed difference is negligible, developers may be willing to learn and program in Java because of the significant advantages the language offers. The introduction of just-in-time compilers for Java may have addressed some of these problems. “Just-in-time compilers have brought Java performance virtually neck-and-neck with C++” (http://www.ncworldmag.com/ncworld/ncw-01-1998/ncw-01-jperf.html).

4.1.2 Language Differences 1. In Java, everything is a class. There are no stand-alone functions. Even main() is a member function!2. In Java, everything is a reference, so the programmer must make sure that memory is allocated properly (using new!), but does not explicitly de-allocate memory.3. In Java, all arrays and objects are passed-by-reference, so a method can change any object that is passed to it.4. Java has built-in graphics capabilities, while in C++ the graphics parts of an application are vendor-specific.5. Java can be used to write both stand-alone programs (applications) and programs that can be run over the Internet by a Browser (Applets). 4.2 Physical Differences 1 Java Has No Pointers – The referencing and dereferencing of objects is handled for you automatically by Java. Java does not allow you to manipulate pointers or memory addresses of any kind: 2 Java Has No Global Variables – In Java, every field and method is declared within a class and forms part of that class. The fields and methods of a class are known as the members of a class.3 Java Does Not Support Multiple Inheritance – C++ supports multiple inheritance of method implementations from more than one superclass at a time. The Java language designers chose to avoid the added compl

Внимание, отключите Adblock

Вы посетили наш сайт со включенным блокировщиком рекламы!
Ссылка для скачивания станет доступной сразу после отключения Adblock!

Скачать
Рефераты на английском языке Differences Between Java And C++ Essay, Research Paper DIFFERENCES BETWEEN JAVA AND C++1 INTRODUCTION Since its release in 1995, Java has been
Оценок: 1010 (Средняя 5 из 5)

Наверняка у вас есть товары или услуги, продажа которых приносит вам максимальную прибыль. Для быстрого старта в сети вам необходимо создание посадочной страницы (одностраничного сайта), на которой будет размещена информация о маржинальных товарах/услугах интернет магазина. За 8 лет опыта разработки конверсионных страниц мы выработали оптимальную структуру, которая позволит привлекать через landing page больше продаж. На такую структуру «одевается» ваш контент — фирменный стиль, тексты, фотографии, уникальные торговые предложения, после чего страница выходит в свет. Разработка лендинга и запуск в сети — до 7 рабочих дней. Стоит отметить, что в разработку самой посадочной страницы входит и написание копирайтером продающих текстов для вашего бизнеса, чтобы каждый посетитель страницы захотел совершить покупку именно у вас. Результат: качественно разработаная продающая посадочная страница, которая готова приносить вам новых клиентов.

© 2016 - 2022 BigEdu.ru