

{"id":11151,"date":"2018-03-20T06:25:02","date_gmt":"2018-03-20T06:25:02","guid":{"rendered":"https:\/\/data-flair.training\/blogs\/?p=11151"},"modified":"2026-05-28T17:51:04","modified_gmt":"2026-05-28T12:21:04","slug":"java-garbage-collection-algorithm","status":"publish","type":"post","link":"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/","title":{"rendered":"Java Garbage Collection Algorithm &#8211; Mark and Sweep Algorithm"},"content":{"rendered":"<div class='__iawmlf-post-loop-links' style='display:none;' data-iawmlf-post-links='[{&quot;id&quot;:1892,&quot;href&quot;:&quot;https:\\\/\\\/www.oracle.com\\\/in\\\/java\\\/index.html&quot;,&quot;archived_href&quot;:&quot;http:\\\/\\\/web-wp.archive.org\\\/web\\\/20180309182901\\\/https:\\\/\\\/www.oracle.com\\\/in\\\/java\\\/index.html&quot;,&quot;redirect_href&quot;:&quot;&quot;,&quot;checks&quot;:[{&quot;date&quot;:&quot;2025-12-10 06:58:27&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2025-12-14 08:15:54&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2025-12-23 01:57:16&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2025-12-29 01:19:47&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-01-02 23:36:00&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-01-06 06:22:14&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-01-12 06:21:18&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-01-15 12:15:57&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-01-25 12:34:15&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-02-02 15:49:19&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-02-09 12:30:57&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-02-13 10:51:51&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-02-26 10:36:53&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-02 04:16:22&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-05 09:34:50&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-09 07:51:38&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-14 06:56:16&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-17 17:15:41&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-23 03:11:32&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-28 14:33:25&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-02 05:56:29&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-06 15:00:44&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-09 19:26:12&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-15 15:14:38&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-22 14:49:34&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-28 14:05:34&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-05-08 06:18:41&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-05-11 07:09:04&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-05-14 19:30:32&quot;,&quot;http_code&quot;:404},{&quot;date&quot;:&quot;2026-05-18 11:05:18&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-05-26 06:56:11&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-05-30 09:54:37&quot;,&quot;http_code&quot;:200}],&quot;broken&quot;:false,&quot;last_checked&quot;:{&quot;date&quot;:&quot;2026-05-30 09:54:37&quot;,&quot;http_code&quot;:200},&quot;process&quot;:&quot;done&quot;}]'><\/div>\n<p>In the last tutorial, we studied <strong><a href=\"https:\/\/data-flair.training\/blogs\/garbage-collection-in-java\/\">garbage collection in Java.<\/a> H<\/strong>ere, we will learn about the different types of garbage collection algorithms in Java: the Mark and Sweep algorithm. Along with this, we will discuss the phases of this algorithm.<\/p>\n<p>So, let us start the Java Garbage Collection Algorithm.<\/p>\n<div id=\"attachment_11442\" style=\"width: 1210px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Java-Garbage-Collection-Algorithm-01.jpg\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-11442\" class=\"wp-image-11442 size-full\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Java-Garbage-Collection-Algorithm-01.jpg\" alt=\"Java Garbage Collection Algorithm\" width=\"1200\" height=\"628\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Java-Garbage-Collection-Algorithm-01.jpg 1200w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Java-Garbage-Collection-Algorithm-01-150x79.jpg 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Java-Garbage-Collection-Algorithm-01-300x157.jpg 300w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Java-Garbage-Collection-Algorithm-01-768x402.jpg 768w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Java-Garbage-Collection-Algorithm-01-1024x536.jpg 1024w\" sizes=\"auto, (max-width: 1200px) 100vw, 1200px\" \/><\/a><p id=\"caption-attachment-11442\" class=\"wp-caption-text\">Java Garbage Collection Algorithm &#8211; Mark and Sweep Algorithm<\/p><\/div>\n<h3>Garbage Collection Algorithm in Java<\/h3>\n<p>Java Garbage Collection Algorithms are used to remove the unreachable objects, it always run in the background. There are different types of Garbage Collection Algorithms in Java that run in the background, and among them, one is the Mark and Sweep algorithm.<\/p>\n<p><strong><a href=\"https:\/\/data-flair.training\/blogs\/interface-in-java\/\">Do you know What is Interface in Java?<\/a><\/strong><\/p>\n<h3>Mark and Sweep Algorithm<\/h3>\n<p>An algorithm for Java Garbage Collection should basically perform two functions. Firstly, it should locate and detect unreachable objects, and secondly, it should free the space from the memory heap so that it can be used by the programmer again.<\/p>\n<p>The two phases of the Java Garbage Collection Algorithm are \u2013<\/p>\n<h4>a. Mark Phase<\/h4>\n<p>Mark Garbage Collection Algorithm in Java, at the point when a question is made, its check bit is set to 0(false). In the Mark stage, we set the marked bit for all the reachable items (or the objects which a client can allude to) to 1(true). Presently, to play out this task, we just need to complete a diagram traversal; a depth-first look approach would work for us. Here we can consider each question as a hub, and after that, every one of the hubs (protests) that are reachable from this hub (protest) is gone too, and it goes ahead till we have gone by all the reachable hubs.<\/p>\n<ul>\n<li>Root is a variable that accesses a protest and is specifically available as a local variable. We will accept that we have one root as it is.<\/li>\n<\/ul>\n<ul>\n<li>We can get to the mark bit for a protest by: markedBit(obj).<\/li>\n<\/ul>\n<p><strong>Related Topics &#8211;<\/strong> <a href=\"https:\/\/data-flair.training\/blogs\/decision-making-in-java\/\"><strong>Decision Making in Java Programming<\/strong><\/a> &amp;\u00a0<a href=\"https:\/\/data-flair.training\/blogs\/java-exception\/\"><strong>Java Exception Handling\u00a0<\/strong><\/a><\/p>\n<p><strong>Mark Collection Algorithm &#8211;<\/strong><\/p>\n<p>Mark(root)<\/p>\n<p>If markedBit(root) = false then<\/p>\n<p>markedBit(root) = true<\/p>\n<p>For each v referenced by a root<\/p>\n<p>Mark(v)<\/p>\n<h4>b. Sweep Phase<\/h4>\n<p>Sweep Garbage Collection Algorithm in Java, as the name suggests, &#8220;clears&#8221; the inaccessible objects, i.e., it clears the stored memory for all the inaccessible objects. Each one of those items whose check esteem is set to false is cleared from the stack memory, and for every single other question (reachable articles), the stamped bit is set to false.<\/p>\n<p>Presently, the check an incentive for all the reachable articles is set to false since we will run the calculation (if required), and again we will experience the stamping stage to check all the reachable items.<\/p>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/overloading-vs-overriding\/\"><strong>Must Read Method Overloading vs Overriding in Java in detail<\/strong><\/a><\/p>\n<p><strong>Sweep Collection Algorithm \u2013<\/strong><\/p>\n<p>Sweep()<\/p>\n<p>For each object p in a heap<\/p>\n<p>If markedBit(p) = true then<\/p>\n<p>markedBit(p) = false<\/p>\n<p>else<\/p>\n<p>heap.release(p)<\/p>\n<p>It is also called<em> a tracing garbage collector<\/em> because it traces the objects.<\/p>\n<p><strong>Example \u2013<\/strong><\/p>\n<p>1. Marked bits set as false.<\/p>\n<p>2. Reachable objects set as true.<\/p>\n<p>3. Non-reachable is clear from the heap.<\/p>\n<h3>Pros &amp; Cons of Mark and Sweep Algorithm<\/h3>\n<p>Advantages and Disadvantages of the Mark and Sweep Algorithm:<\/p>\n<div id=\"attachment_11456\" style=\"width: 1090px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Mark-and-Sweep-Algorithm-01.jpg\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-11456\" class=\"wp-image-11456 size-full\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Mark-and-Sweep-Algorithm-01.jpg\" alt=\"Java Garbage Collection Algorithm - Mark and Sweep Algorithm\" width=\"1080\" height=\"1080\" srcset=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Mark-and-Sweep-Algorithm-01.jpg 1080w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Mark-and-Sweep-Algorithm-01-150x150.jpg 150w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Mark-and-Sweep-Algorithm-01-300x300.jpg 300w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Mark-and-Sweep-Algorithm-01-768x768.jpg 768w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Mark-and-Sweep-Algorithm-01-1024x1024.jpg 1024w, https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Mark-and-Sweep-Algorithm-01-100x100.jpg 100w\" sizes=\"auto, (max-width: 1080px) 100vw, 1080px\" \/><\/a><p id=\"caption-attachment-11456\" class=\"wp-caption-text\">Advantages &amp; Disadvantages of Mark and Sweep Algorithm<\/p><\/div>\n<h4>Advantages of the Mark and Sweep Algorithm<\/h4>\n<ul>\n<li>It is a cyclic process, i.e., it is an infinite loop.<\/li>\n<li>No additional overheads occur during the execution of an algorithm.<\/li>\n<li>This algorithm works when the space left in the memory is quite low.<\/li>\n<li>The Mark and Sweep algorithm works only when the garbage collector is active, so that it does not disturb the execution of a program.<\/li>\n<li>It searches for every object that is not in use. Hence, removing the unused element from the depth.<\/li>\n<\/ul>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/abstraction-in-java\/\"><strong>Read the Difference between Abstraction &amp; Encapsulation in Java<\/strong><\/a><\/p>\n<h4>Disadvantages of the Mark and Sweep Algorithm<\/h4>\n<ul>\n<li>Normal program execution stops while the Java garbage collection algorithm runs. Causing a hindrance in running the application.<\/li>\n<li>It runs several times differently on a program.<\/li>\n<li>The smaller free space is not consumed properly and remains unused, resulting in a loss of memory.<\/li>\n<\/ul>\n<p>So, this was all about the Java Garbage Collection Algorithm. Hope you like our explanation.<\/p>\n<h3>Conclusion<\/h3>\n<p>Hence, in this tutorial, we learned about the Java garbage collection algorithm, different types of collection algorithms: the Java Mark and Sweep algorithm, and the pros and cons of the Mark and Sweep Algorithm in Java. In the next tutorial, we will learn about the <a href=\"https:\/\/data-flair.training\/blogs\/island-of-isolation-in-java\/\"><strong>island of isolation<\/strong><\/a>.<\/p>\n<p>See also &#8211;\u00a0<a href=\"https:\/\/data-flair.training\/blogs\/java-file-class\/\"><strong>Java.io.File Class<\/strong><\/a><\/p>\n<p><strong><a href=\"https:\/\/www.oracle.com\/in\/java\/index.html\">For reference<\/a><\/strong><\/p>\n","protected":false},"excerpt":{"rendered":"<p>In the last tutorial, we studied garbage collection in Java. Here, we will learn about the different types of garbage collection algorithms in Java: the Mark and Sweep algorithm. Along with this, we will&#46;&#46;&#46;<\/p>\n","protected":false},"author":5,"featured_media":11442,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[32],"tags":[5016,7517,7590,8566,8568],"class_list":["post-11151","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-java","tag-garbage-collection-algorithm-in-data-structure","tag-java-garbage-collection-algorithm","tag-java-mark-and-sweep-algorithm","tag-mark-and-sweep-algorithm-in-java","tag-mark-and-sweep-garbage-collection"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Java Garbage Collection Algorithm - Mark and Sweep Algorithm - DataFlair<\/title>\n<meta name=\"description\" content=\"Garbage Collection Algorithm in Java, types of Java Garbage Collection Algorithm, Advantages &amp; Disadvantages of Mark and Sweep Collection Algorithm\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Java Garbage Collection Algorithm - Mark and Sweep Algorithm - DataFlair\" \/>\n<meta property=\"og:description\" content=\"Garbage Collection Algorithm in Java, types of Java Garbage Collection Algorithm, Advantages &amp; Disadvantages of Mark and Sweep Collection Algorithm\" \/>\n<meta property=\"og:url\" content=\"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/\" \/>\n<meta property=\"og:site_name\" content=\"DataFlair\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/DataFlairWS\/\" \/>\n<meta property=\"article:published_time\" content=\"2018-03-20T06:25:02+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2026-05-28T12:21:04+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Java-Garbage-Collection-Algorithm-01.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1200\" \/>\n\t<meta property=\"og:image:height\" content=\"628\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"DataFlair Team\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@DataFlairWS\" \/>\n<meta name=\"twitter:site\" content=\"@DataFlairWS\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"DataFlair Team\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Java Garbage Collection Algorithm - Mark and Sweep Algorithm - DataFlair","description":"Garbage Collection Algorithm in Java, types of Java Garbage Collection Algorithm, Advantages & Disadvantages of Mark and Sweep Collection Algorithm","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/","og_locale":"en_US","og_type":"article","og_title":"Java Garbage Collection Algorithm - Mark and Sweep Algorithm - DataFlair","og_description":"Garbage Collection Algorithm in Java, types of Java Garbage Collection Algorithm, Advantages & Disadvantages of Mark and Sweep Collection Algorithm","og_url":"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/","og_site_name":"DataFlair","article_publisher":"https:\/\/www.facebook.com\/DataFlairWS\/","article_published_time":"2018-03-20T06:25:02+00:00","article_modified_time":"2026-05-28T12:21:04+00:00","og_image":[{"width":1200,"height":628,"url":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Java-Garbage-Collection-Algorithm-01.jpg","type":"image\/jpeg"}],"author":"DataFlair Team","twitter_card":"summary_large_image","twitter_creator":"@DataFlairWS","twitter_site":"@DataFlairWS","twitter_misc":{"Written by":"DataFlair Team","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/#article","isPartOf":{"@id":"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/"},"author":{"name":"DataFlair Team","@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/person\/7f83c342f5d1632d6f7b4b0b0f447823"},"headline":"Java Garbage Collection Algorithm &#8211; Mark and Sweep Algorithm","datePublished":"2018-03-20T06:25:02+00:00","dateModified":"2026-05-28T12:21:04+00:00","mainEntityOfPage":{"@id":"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/"},"wordCount":779,"commentCount":0,"publisher":{"@id":"https:\/\/data-flair.training\/blogs\/#organization"},"image":{"@id":"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/#primaryimage"},"thumbnailUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Java-Garbage-Collection-Algorithm-01.jpg","keywords":["garbage collection algorithm in data structure","Java Garbage Collection Algorithm","Java Mark and Sweep Algorithm","Mark and Sweep Algorithm in java","mark and sweep garbage collection"],"articleSection":["Java Tutorials"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/","url":"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/","name":"Java Garbage Collection Algorithm - Mark and Sweep Algorithm - DataFlair","isPartOf":{"@id":"https:\/\/data-flair.training\/blogs\/#website"},"primaryImageOfPage":{"@id":"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/#primaryimage"},"image":{"@id":"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/#primaryimage"},"thumbnailUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Java-Garbage-Collection-Algorithm-01.jpg","datePublished":"2018-03-20T06:25:02+00:00","dateModified":"2026-05-28T12:21:04+00:00","description":"Garbage Collection Algorithm in Java, types of Java Garbage Collection Algorithm, Advantages & Disadvantages of Mark and Sweep Collection Algorithm","breadcrumb":{"@id":"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/#primaryimage","url":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Java-Garbage-Collection-Algorithm-01.jpg","contentUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2018\/03\/Java-Garbage-Collection-Algorithm-01.jpg","width":1200,"height":628,"caption":"Java Garbage Collection Algorithm"},{"@type":"BreadcrumbList","@id":"https:\/\/data-flair.training\/blogs\/java-garbage-collection-algorithm\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Blog Home","item":"https:\/\/data-flair.training\/blogs\/"},{"@type":"ListItem","position":2,"name":"Java Tutorials","item":"https:\/\/data-flair.training\/blogs\/category\/java\/"},{"@type":"ListItem","position":3,"name":"Java Garbage Collection Algorithm &#8211; Mark and Sweep Algorithm"}]},{"@type":"WebSite","@id":"https:\/\/data-flair.training\/blogs\/#website","url":"https:\/\/data-flair.training\/blogs\/","name":"DataFlair","description":"Learn Today. Lead Tomorrow.","publisher":{"@id":"https:\/\/data-flair.training\/blogs\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/data-flair.training\/blogs\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/data-flair.training\/blogs\/#organization","name":"DataFlair","url":"https:\/\/data-flair.training\/blogs\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/logo\/image\/","url":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2016\/07\/Data-Flair.png","contentUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2016\/07\/Data-Flair.png","width":106,"height":48,"caption":"DataFlair"},"image":{"@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/DataFlairWS\/","https:\/\/x.com\/DataFlairWS","https:\/\/www.linkedin.com\/company\/dataflair-web-services-pvt-ltd\/","https:\/\/www.youtube.com\/user\/DataFlairWS"]},{"@type":"Person","@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/person\/7f83c342f5d1632d6f7b4b0b0f447823","name":"DataFlair Team","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/4cf3a74600d131330b8c481d519afd1574093ed89f6d3396a95393ad223eb7cd?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/4cf3a74600d131330b8c481d519afd1574093ed89f6d3396a95393ad223eb7cd?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/4cf3a74600d131330b8c481d519afd1574093ed89f6d3396a95393ad223eb7cd?s=96&d=mm&r=g","caption":"DataFlair Team"},"description":"DataFlair Team creates expert-level guides on programming, Java, Python, C++, DSA, AI, ML, data Science, Android, Flutter, MERN, Web Development, and technology. Our goal is to empower learners with easy-to-understand content. Explore our resources for career growth and practical learning.","url":"https:\/\/data-flair.training\/blogs\/author\/dfteam1\/"}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts\/11151","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/comments?post=11151"}],"version-history":[{"count":10,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts\/11151\/revisions"}],"predecessor-version":[{"id":148486,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts\/11151\/revisions\/148486"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/media\/11442"}],"wp:attachment":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/media?parent=11151"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/categories?post=11151"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/tags?post=11151"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}