The Gateway to Computer Science Excellence
+5 votes

Which of the following programming language(s) provides garbage collection automatically

  1. Lisp
  2. C++
  3. Fortan
  4. C
in Programming by Veteran (105k points) | 2.1k views

3 Answers

+8 votes
Best answer

Except Lisp all language C, C++, Fortran have manual memory management.So Lisp provide automatic garbage collection.

Reference :Garbage Collection

by Boss (38.7k points)
selected by
any reference plz,,
+10 votes

Answer is A) LISP

Because C,C++ and FORTRAN does not provide that. 

by Boss (35.7k points)
Loved the explanation.
+3 votes

Answer :  Lisp

Lisp is especially notable as both the first functional programming language and the first language to introduce garbage collection.

by Boss (45.4k points)
edited by

The reason behind my answer is I looked for lisp on google because i don't know anything about it ,but C++ is a object oriented programming Language like Java and C# and Java  and C# has garbage collector so i thought C++ must be having garbage collector.

in case of C Lang we have to write a code for garbage collector .

Ok but anyway C++ does not provide garbage collection automatically .
I have corrected my answer...
what is garbage collector..?????  :'(

In computer science, garbage collection (GC) is a form of automatic memory management. The garbage collector, or just collector, attempts to reclaim garbage, or memory occupied by objects that are no longer in use by the program. 

Refrence :

Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
50,737 questions
57,306 answers
105,014 users