{"id":83880,"date":"2021-09-08T09:00:26","date_gmt":"2021-09-08T03:30:26","guid":{"rendered":"https:\/\/techvidvan.com\/tutorials\/?p=83880"},"modified":"2021-09-08T09:00:26","modified_gmt":"2021-09-08T03:30:26","slug":"cpp-exception-handling","status":"publish","type":"post","link":"https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/","title":{"rendered":"C++ Exception Handling"},"content":{"rendered":"<p>A programmer can get many advantages while using the C++ programming language. It offers various features and functionalities to the programmers. C++ offers a very powerful feature named Exception Handling.<\/p>\n<h3>What is Exception Handling in C++?<\/h3>\n<p>Sometimes when you execute a program, you may face exceptions like run-time abnormal conditions. It arises due to some abnormal conditions such as dividing a number by zero. It arises while a program is running.<\/p>\n<p>In C++, you can perform exception handling with the help of three keywords such as try, catch and throw.<\/p>\n<ul>\n<li>try:- Mainly used to represent a block of code which might throw an exception.<\/li>\n<li>catch:- block of code inside this keyword will get executed when an exception is thrown.<\/li>\n<li>throw:- Mainly used to throw an exception.<\/li>\n<\/ul>\n<h3>Why to use C++ Exception Handling?<\/h3>\n<ul>\n<li>To handle errors, you can also use if-else statements in your program code. But it is bad practice to use if-else statements to handle errors. Because it will make your code less readable and maintainable. And also the conditions and the code to handle errors will get mixed up with the normal flow. That\u2019s when, Exception handling becomes useful.<\/li>\n<li>With the help of exception handling, you can specify the exception which a function throws using the throw keyword.<\/li>\n<li>In C++, you can also create a hierarchy of exception objects, exceptions in namespaces or classes and categorize them according to types.<\/li>\n<\/ul>\n<h4>C++ Exceptions<\/h4>\n<p>In C++, while executing a program, different types of errors can occur like coding errors made by the programmer, wrong input errors and other errors.<br \/>\nThen it will give an error message. To put it short, it will throw you an exception.<\/p>\n<h4>try and catch C++<\/h4>\n<p>You have to use try and catch statements to perform exception handling in C++. The try block is used to represent a block of code which might throw an exception. And the catch block is used to handle that exception.<\/p>\n<p><strong>Syntax:-<\/strong><\/p>\n<p>If your try block raises more than one exception then you can use multiple catch statements to catch different types of exceptions.<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">try {\n   \/\/ code\n} catch( Exception_Name e1 ) {\n   \/\/ catch block\n} catch( Exception_Name e2 ) {\n   \/\/ catch block\n} \n<\/pre>\n<h4>Throwing Exceptions in C++<\/h4>\n<p>You can make use of throw statements to throw exceptions anywhere within the program code. Below is an example of throwing an example:-<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">int divide(int a, int b) {\n   if( b == 0 ) {\n      throw \"You are dividing a number by 0!\";\n   }\n   return (a\/b);\n}<\/pre>\n<p>The above will throw an exception when you are dividing a number by zero.<\/p>\n<h4>Catching Exceptions<\/h4>\n<p>The catch statement is useful to catch any exception. You can also specify what type of exception you want to catch.<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">try {\n   \/\/ code\n} catch( Exception1 e ) {\n  \/\/ code to handle exception\n}<\/pre>\n<p>The above will catch an exception named Exception1.<\/p>\n<p><strong>Example without try and catch statements<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">#include &lt;iostream&gt;\nusing namespace std;\nint divide (int a, int b)\n{\n  return (a \/ b);\n}\n\nint main ()\n{\n  int x = 5;\n  int y = 0;\n  int z = 0;\n  z = divide (x, y);\n  cout &lt;&lt; z &lt;&lt; endl;\n  return 0;\n}\n<\/pre>\n<p><strong>Output:-<\/strong><\/p>\n<div class=\"code-output\">Floating point exception<\/div>\n<p>Writing the above program code with try and catch statements:-<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">#include &lt;iostream&gt;\nusing namespace std;\nint divide (int a, int b)\n{\n  if(b==0){\n  \tthrow \"You are dividing a number by zero!\";\n  }\n  return (a\/b);\n}\n\nint main ()\n{\n  int x = 5;\n  int y = 0;\n  int z = 0;\n  try{\n  z = divide (x, y);\n  cout &lt;&lt; z &lt;&lt; endl;\n  }catch (const char* e){\n  \tcerr &lt;&lt; e &lt;&lt; endl;\n  }\n\n  return 0;\n}<\/pre>\n<p><strong>Output:-<\/strong><\/p>\n<div class=\"code-output\">You are dividing a number by zero!<\/div>\n<h3>Exception Handling in C++<\/h3>\n<p>1. In C++, you can make use of a special catch block named \u2018catch all\u2019 catch(&#8230;) which is used to catch all types of exceptions.<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">#include &lt;iostream&gt;\nusing namespace std;\n\nint main()\n{\n    try {\n    throw 5;\n    }\n    catch (char *exp) {\n   \t cout &lt;&lt; \"Catch the Exception!\" &lt;&lt; exp;\n    }\n    catch (...) {\n   \t cout &lt;&lt; \"Testing!\\n\";\n    }\n    return 0;\n}\n<\/pre>\n<p><strong>Output:-<\/strong><\/p>\n<div class=\"code-output\">Testing!<\/div>\n<p>2. Primitive types cannot be implicitly converted. Below, \u2018T\u2019 is not implicitly converted to int.<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">#include &lt;iostream&gt;\nusing namespace std;\n\nint main()\n{\n    try {\n    throw 'T';\n    }\n    catch (int a) {\n   \t cout &lt;&lt; \"Catch the expression!\" &lt;&lt; a;\n    }\n    catch (...) {\n   \t cout &lt;&lt; \"Just Testing!\\n\";\n    }\n    return 0;\n}\n<\/pre>\n<p><strong>Output:-<\/strong><\/p>\n<div class=\"code-output\">Just Testing!<\/div>\n<p>3. Suppose an exception is thrown and if it did not catch anywhere then the program will terminate abnormally.<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">#include &lt;iostream&gt;\nusing namespace std;\n\nint main()\n{\n    try {\n    throw 'T';\n    }\n    catch (int a) {\n   \t cout &lt;&lt; \"Catch an exception!\";\n    }\n    return 0;\n}\n<\/pre>\n<p><strong>Output:-<\/strong><\/p>\n<div class=\"code-output\">terminate called after throwing an instance of &#8216;char&#8217;<br \/>\nAborted<\/div>\n<p>You can write your own unexpected function to change the above abnormality.<\/p>\n<ul>\n<li>In C++, the compiler does not check if the exception is caught or not. But in Java, this is possible.<\/li>\n<li>The C++ programming language has a special exception class which is the base class for all standard exceptions.<\/li>\n<li>You can also perform nested try\/catch statements. You can also rethrow an exception using \u2018throw;\u2019.\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">#include &lt;iostream&gt;\nusing namespace std;\n\nint main()\n{\n    try {\n   \t try {\n   \t\t throw 10;\n   \t }\n   \t catch (int x) {\n   \t\t cout &lt;&lt; \"Testing1.... \\n\";\n   \t\t throw;\n   \t }\n    }\n    catch (int x) {\n   \t cout &lt;&lt; \"Testing2.... \";\n    }\n    return 0;\n}\n<\/pre>\n<p><strong>Output:-<\/strong><\/p>\n<div class=\"code-output\">Testing1&#8230;.<br \/>\nTesting2&#8230;.<\/div>\n<\/li>\n<li>Whenever an exception is thrown, the objects created inside the try\/block statements are destructed.\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">#include &lt;iostream&gt;\nusing namespace std;\nclass Tech{\npublic:\n  Tech() { cout &lt;&lt; \"It is the constructor of Tech!\" &lt;&lt; endl; }\n  ~Tech() { cout &lt;&lt; \"It is the destructor of Tech!\" &lt;&lt; endl; }\n};\n \nint main()\n{\n  try {\n    \tTech t1;\n    \tthrow 5;\n  }\n  catch (int x) {\n    \tcout &lt;&lt; \"Catch an exception \" &lt;&lt; x &lt;&lt; endl;\n  }\n}\n<\/pre>\n<p><strong>Output:-<\/strong><\/p>\n<div class=\"code-output\">It is the constructor of Tech!<br \/>\nIt is the destructor of Tech!<br \/>\nCatch an exception 5<\/div>\n<\/li>\n<\/ul>\n<h3>C++ Standard Exceptions<\/h3>\n<p>C++ also offers various standard exceptions which are defined in &lt;exception&gt;. You can use these in your program.<br \/>\nBelow is the table of the standard exceptions:-<\/p>\n<table>\n<tbody>\n<tr>\n<td><span style=\"font-weight: 400\">Serial No.<\/span><\/td>\n<td><b>Exception and Definition<\/b><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400\">1<\/span><\/td>\n<td><b>std::exception<\/b><\/p>\n<p><span style=\"font-weight: 400\">It is the parent class of all standard C++ exceptions. Also an exception.<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400\">2<\/span><\/td>\n<td><b>std::bad_alloc<\/b><\/p>\n<p><span style=\"font-weight: 400\">Used to throw exceptions by <\/span><b>new<\/b><span style=\"font-weight: 400\">.<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400\">3<\/span><\/td>\n<td><b>std::bad_cast<\/b><\/p>\n<p><span style=\"font-weight: 400\">Used to throw exceptions by <\/span><b>dynamic_cast<\/b><span style=\"font-weight: 400\">.<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400\">4<\/span><\/td>\n<td><b>std::bad_exception<\/b><\/p>\n<p><span style=\"font-weight: 400\">Used to handle unexpected exceptions.<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400\">5<\/span><\/td>\n<td><b>std::bad_typeid<\/b><\/p>\n<p><span style=\"font-weight: 400\">Used to throw exceptions by <\/span><b>typeid<\/b><span style=\"font-weight: 400\">.<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400\">6<\/span><\/td>\n<td><b>std::logic_error<\/b><\/p>\n<p><span style=\"font-weight: 400\">You can easily detect an exception just by reading the code.<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400\">7<\/span><\/td>\n<td><b>std::domain_error<\/b><\/p>\n<p><span style=\"font-weight: 400\">Used to throw an exception whenever a mathematically invalid domain is used.<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400\">8<\/span><\/td>\n<td><b>std::invalid_argument<\/b><\/p>\n<p><span style=\"font-weight: 400\">Exception is thrown due to invalid arguments.<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400\">9<\/span><\/td>\n<td><b>std::length_error<\/b><\/p>\n<p><span style=\"font-weight: 400\">Exception is thrown whenever a too big std::string is generated.<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400\">10<\/span><\/td>\n<td><b>std::out_of_range<\/b><\/p>\n<p><span style=\"font-weight: 400\">Exception is thrown by the \u2018at\u2019 method.<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400\">11<\/span><\/td>\n<td><b>std::runtime_error<\/b><\/p>\n<p><span style=\"font-weight: 400\">You cannot detect an exception by reading the code.<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400\">12<\/span><\/td>\n<td><b>std::overflow_error<\/b><\/p>\n<p><span style=\"font-weight: 400\">In the program code, if a mathematical overflow occurs then this exception is thrown.<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400\">13<\/span><\/td>\n<td><b>std::range_error<\/b><\/p>\n<p><span style=\"font-weight: 400\">Exception is thrown when you tend to store value out of the range.<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400\">14<\/span><\/td>\n<td><b>std::underflow_error<\/b><\/p>\n<p><span style=\"font-weight: 400\">In the program code, if a mathematical underflow occurs then this exception is thrown.<\/span><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>Defining New Exceptions in C++<\/h3>\n<p>In C++, you can also define your own exceptions. It can possible by inheriting and overriding exception class functionality.<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">#include &lt;iostream&gt;\n#include &lt;exception&gt;\nusing namespace std;\n\nstruct JustException: public exception{\n   const char * Tech() const throw () {\n  \treturn \"Testing C++ exception!\";\n   }\n};\n \nint main() {\n   try {\n  \tthrow JustException();\n   } catch(JustException&amp; e) {\n  \tstd::cout &lt;&lt; \"Caught JustException!\" &lt;&lt; std::endl;\n  \tstd::cout &lt;&lt; e.Tech() &lt;&lt; std::endl;\n   } catch(std::exception&amp; e) {\n   }\n}\n<\/pre>\n<p><strong>Output:-<\/strong><\/p>\n<div class=\"code-output\">Caught JustException!<br \/>\nTesting C++ exception!<\/div>\n<p>From above, Tech() is a public method that is provided by the exception class. And later, it is overridden by all the child exception classes.<\/p>\n<h3>Summary<\/h3>\n<p>In this tutorial, we discussed how you can perform exception handling in C++ in detail. We saw what exceptions are and how to handle them in C++. Then we discussed why to use exception handling. We talked over different aspects of exception handling in C++. We also discussed how you can define your own exception in C++.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>A programmer can get many advantages while using the C++ programming language. It offers various features and functionalities to the programmers. C++ offers a very powerful feature named Exception Handling. What is Exception Handling&#46;&#46;&#46;<\/p>\n","protected":false},"author":1,"featured_media":84601,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3405],"tags":[4203,4204,4205],"class_list":["post-83880","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-cpp","tag-c-exception-handling","tag-c-standard-exceptions","tag-exceptions-in-c"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>C++ Exception Handling - TechVidvan<\/title>\n<meta name=\"description\" content=\"Learn what is exception handling in C++ and how to perform it.See what exceptions are and how to handle them in C++.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"C++ Exception Handling - TechVidvan\" \/>\n<meta property=\"og:description\" content=\"Learn what is exception handling in C++ and how to perform it.See what exceptions are and how to handle them in C++.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/\" \/>\n<meta property=\"og:site_name\" content=\"TechVidvan\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/TechVidvan\/\" \/>\n<meta property=\"article:published_time\" content=\"2021-09-08T03:30:26+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/techvidvan.com\/tutorials\/wp-content\/uploads\/2021\/07\/C-Exception-Handling.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=\"TechVidvan Team\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@vidvantech\" \/>\n<meta name=\"twitter:site\" content=\"@vidvantech\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"TechVidvan Team\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 minutes\" \/>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"C++ Exception Handling - TechVidvan","description":"Learn what is exception handling in C++ and how to perform it.See what exceptions are and how to handle them in C++.","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:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/","og_locale":"en_US","og_type":"article","og_title":"C++ Exception Handling - TechVidvan","og_description":"Learn what is exception handling in C++ and how to perform it.See what exceptions are and how to handle them in C++.","og_url":"https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/","og_site_name":"TechVidvan","article_publisher":"https:\/\/www.facebook.com\/TechVidvan\/","article_published_time":"2021-09-08T03:30:26+00:00","og_image":[{"width":1200,"height":628,"url":"https:\/\/techvidvan.com\/tutorials\/wp-content\/uploads\/2021\/07\/C-Exception-Handling.jpg","type":"image\/jpeg"}],"author":"TechVidvan Team","twitter_card":"summary_large_image","twitter_creator":"@vidvantech","twitter_site":"@vidvantech","twitter_misc":{"Written by":"TechVidvan Team","Est. reading time":"6 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/#article","isPartOf":{"@id":"https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/"},"author":{"name":"TechVidvan Team","@id":"https:\/\/techvidvan.com\/tutorials\/#\/schema\/person\/e9c26e74dd3d87421f7ada9433b8cd22"},"headline":"C++ Exception Handling","datePublished":"2021-09-08T03:30:26+00:00","mainEntityOfPage":{"@id":"https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/"},"wordCount":963,"commentCount":0,"publisher":{"@id":"https:\/\/techvidvan.com\/tutorials\/#organization"},"image":{"@id":"https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/#primaryimage"},"thumbnailUrl":"https:\/\/techvidvan.com\/tutorials\/wp-content\/uploads\/2021\/07\/C-Exception-Handling.jpg","keywords":["C++ Exception Handling","C++ Standard Exceptions","Exceptions in C++"],"articleSection":["C++ Tutorials"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/","url":"https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/","name":"C++ Exception Handling - TechVidvan","isPartOf":{"@id":"https:\/\/techvidvan.com\/tutorials\/#website"},"primaryImageOfPage":{"@id":"https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/#primaryimage"},"image":{"@id":"https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/#primaryimage"},"thumbnailUrl":"https:\/\/techvidvan.com\/tutorials\/wp-content\/uploads\/2021\/07\/C-Exception-Handling.jpg","datePublished":"2021-09-08T03:30:26+00:00","description":"Learn what is exception handling in C++ and how to perform it.See what exceptions are and how to handle them in C++.","breadcrumb":{"@id":"https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/#primaryimage","url":"https:\/\/techvidvan.com\/tutorials\/wp-content\/uploads\/2021\/07\/C-Exception-Handling.jpg","contentUrl":"https:\/\/techvidvan.com\/tutorials\/wp-content\/uploads\/2021\/07\/C-Exception-Handling.jpg","width":1200,"height":628,"caption":"C++ Exception Handling"},{"@type":"BreadcrumbList","@id":"https:\/\/techvidvan.com\/tutorials\/cpp-exception-handling\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/techvidvan.com\/tutorials\/"},{"@type":"ListItem","position":2,"name":"C++ Exception Handling"}]},{"@type":"WebSite","@id":"https:\/\/techvidvan.com\/tutorials\/#website","url":"https:\/\/techvidvan.com\/tutorials\/","name":"TechVidvan Blogs","description":"","publisher":{"@id":"https:\/\/techvidvan.com\/tutorials\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/techvidvan.com\/tutorials\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/techvidvan.com\/tutorials\/#organization","name":"TechVidvan","url":"https:\/\/techvidvan.com\/tutorials\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/techvidvan.com\/tutorials\/#\/schema\/logo\/image\/","url":"https:\/\/techvidvan.com\/tutorials\/wp-content\/uploads\/2024\/03\/techvidvan-logo-200x50-1.webp","contentUrl":"https:\/\/techvidvan.com\/tutorials\/wp-content\/uploads\/2024\/03\/techvidvan-logo-200x50-1.webp","width":200,"height":50,"caption":"TechVidvan"},"image":{"@id":"https:\/\/techvidvan.com\/tutorials\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/TechVidvan\/","https:\/\/x.com\/vidvantech"]},{"@type":"Person","@id":"https:\/\/techvidvan.com\/tutorials\/#\/schema\/person\/e9c26e74dd3d87421f7ada9433b8cd22","name":"TechVidvan Team","description":"The TechVidvan Team delivers practical, beginner-friendly tutorials on programming, Java, Python, C++, DSA, AI, ML, data Science, Android, Flutter, MERN, Web Development, and technology. Our experts are here to help you upskill and excel in today\u2019s tech industry."}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/techvidvan.com\/tutorials\/wp-json\/wp\/v2\/posts\/83880","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/techvidvan.com\/tutorials\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/techvidvan.com\/tutorials\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/techvidvan.com\/tutorials\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/techvidvan.com\/tutorials\/wp-json\/wp\/v2\/comments?post=83880"}],"version-history":[{"count":0,"href":"https:\/\/techvidvan.com\/tutorials\/wp-json\/wp\/v2\/posts\/83880\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/techvidvan.com\/tutorials\/wp-json\/wp\/v2\/media\/84601"}],"wp:attachment":[{"href":"https:\/\/techvidvan.com\/tutorials\/wp-json\/wp\/v2\/media?parent=83880"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/techvidvan.com\/tutorials\/wp-json\/wp\/v2\/categories?post=83880"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/techvidvan.com\/tutorials\/wp-json\/wp\/v2\/tags?post=83880"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}