Total members 11889 |It is currently Thu Mar 28, 2024 8:07 pm Login / Join Codemiles

Java

C/C++

PHP

C#

HTML

CSS

ASP

Javascript

JQuery

AJAX

XSD

Python

Matlab

R Scripts

Weka





The difference between C++ and java memory management:
-------------------------------------------------------------


In C and C++, any memory that is allocated on the heap (e.g. using malloc or new) must be explicitly freed by the programmer (e.g. using free or delete). Forgetting to free memory leads to memory leaks, and in long-running programs can lead to the memory usage of the program growing very large.

Java provides garbage collection, meaning that memory is freed automatically when it is no longer reachable by any references. This prevents memory leaks, but can lead to pauses in execution while the garbage collector runs. Also, there is no promise of timely destruction in Java.



_________________
Please recommend my post if you found it helpful


Author:
Beginner
User avatar Posts: 109
Have thanks: 5 time
Post new topic Reply to topic  [ 1 post ] 

  Related Posts  to : C++ & Java memory management!!
 how to create a photo management system using java     -  
 Java Library Database Management System Project     -  
 GDI memory leaks detection     -  
 MATLAB clear memory     -  
 Memory leak detection in C++     -  
 problem with memory alocation     -  
 subtract number from memory locations     -  
 Latest XML parsing/memory usage benchmark     -  
 application on hotel management system     -  
 need project code for time and work management     -  



Topic Tags

Java Basics
cron





Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
All copyrights reserved to codemiles.com 2007-2011
mileX v1.0 designed by codemiles team
Codemiles.com is a participant in the Amazon Services LLC Associates Program, an affiliate advertising program designed to provide a means for sites to earn advertising fees by advertising and linking to Amazon.com