{"id":341,"date":"2021-07-12T21:16:29","date_gmt":"2021-07-12T21:16:29","guid":{"rendered":"https:\/\/www.wikitechy.com\/interview-questions\/?p=341"},"modified":"2021-09-14T05:50:37","modified_gmt":"2021-09-14T05:50:37","slug":"what-is-the-output-of-this-c-code","status":"publish","type":"post","link":"https:\/\/www.wikitechy.com\/interview-questions\/c\/what-is-the-output-of-this-c-code\/","title":{"rendered":"What is the output of this C code ?"},"content":{"rendered":"<h3 id=\"what-is-the-output-of-this-c-code\">What is the output of this C code ?<\/h3>\n<div class=\"code-embed-wrapper\"> <div class=\"code-embed-infos\"> <\/div> <pre class=\"language-c code-embed-pre line-numbers\"  data-start=\"1\" data-line-offset=\"0\"><code class=\"language-c code-embed-code\">Function main() {<br\/>  integer a = 5, b = 7<br\/>  Switch(a) {<br\/>    Case 5: print &quot;I am 5&quot;<br\/>    Break<br\/>    Case b: print &quot;I am not 5&quot;<br\/>    Break<br\/>    Default: print &quot;I am different&quot;<br\/>  }<br\/>}<\/code><\/pre> <\/div>\n<div class=\"TextHeading\">\n<div class=\"hddn\">\n<div class=\"row\">\n<div class=\"col-sm-4\">\n<p>A. I am 5<\/p>\n<\/div>\n<div class=\"col-sm-4\">\n<p>B. I am not 5<\/p>\n<\/div>\n<div class=\"col-sm-4\">\n<p>C. I am different<\/p>\n<\/div>\n<div class=\"col-sm-4\">\n<p>D. Error<\/p>\n<\/div>\n<div class=\"col-sm-4\">\n<p>E. None of these<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<h3 id=\"answer-d-error\"><b>Answer :\u00a0<\/b>D. Error<u><\/u><\/h3>\n<div class=\"subheading\">\n<h2 id=\"explanation\">Explanation:<\/h2>\n<\/div>\n<div class=\"Content\">\n<div class=\"hddn\">\n<ul>\n<li>Break doesn\u2019t have \u201c;\u201d (Semi Colon missing in break command)<\/li>\n<\/ul>\n<\/div>\n<\/div>\n<p>\u00a0<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Answer : D. Error<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1716],"tags":[1739,2023,491,1740,211,2024,2037,2025,2038,2026,203,199,214,198,363,209,205,1745,1743,222,1747,2027,196,212,2028,710,207,366,204,217,2029,288,1744,483,206,2040,2043,2039,2030,2031,2032,2041,2042,2033,2034,1741,1742,1746,2035,2036],"class_list":["post-341","post","type-post","status-publish","format-standard","hentry","category-c","tag-accentur-interview-questions-and-answers","tag-algorithm-for-switch-case-in-c","tag-applied-materials-interview-questions-and-answers","tag-asian-paints-ltd-interview-questions-and-answers","tag-bosch-india-software-interview-questions-and-answers","tag-c-program-for-switch-case-using-function","tag-c-programming-switch-case-examples","tag-c-programming-switch-case-examples-programs","tag-c-programming-switch-case-programs","tag-c-switch-case-statement","tag-capgemini-interview-questions-and-answers","tag-casting-networks-india-pvt-limited-interview-questions-and-answers","tag-cgi-group-inc-interview-questions-and-answers","tag-chetu-interview-questions-and-answers","tag-ciena-corporation-interview-questions-and-answers","tag-collabera-technologies-interview-questions-and-answers","tag-dell-international-services-india-pvt-ltd-interview-questions-and-answers","tag-dhfl-pramerica-life-insurance-company-ltd-interview-questions-and-answers","tag-elico-healthcare-services-ltd-interview-questions-and-answers","tag-flipkart-interview-questions-and-answers","tag-hcl-technol-interview-questions-and-answers","tag-how-does-the-switch-and-break-work-in-c","tag-ibm-interview-questions-and-answers","tag-indecomm-global-services-interview-questions-and-answers","tag-java-switch-statement","tag-mavenir-interview-questions-and-answers","tag-mphasis-interview-questions-and-answers","tag-netapp-interview-questions-and-answers","tag-oracle-corporation-interview-questions-and-answers","tag-peoplestrong-interview-questions-and-answers","tag-program-for-switch-case-with-and-without-break-statement","tag-r-systems-interview-questions-and-answers","tag-raqmiyat-information-technologies-pvt-ltd-interview-questions-and-answers","tag-reliance-industries-ltd-interview-questions-and-answers","tag-sap-labs-india-pvt-ltd-interview-questions-and-answers","tag-switch-case","tag-switch-case-c","tag-switch-case-example-in-c","tag-switch-case-exercises-in-c","tag-switch-case-in-c-programming-examples","tag-switch-case-in-c-programming-questions","tag-switch-case-program-in-c","tag-switch-case-statement-in-c-programming","tag-switch-caseswitch-case-statement-in-c-programming","tag-switch-statement-in-c","tag-tata-aia-life-insurance-interview-questions-and-answers","tag-tech-mahindr-interview-questions-and-answers","tag-the-linde-group-interview-questions-and-answers","tag-what-is-switch-condition","tag-while-c-programming"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.6 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>What is the output of this C code ? - Recursive Function in C Program<\/title>\n<meta name=\"description\" content=\"What is the output of this C code ? - Recursive Function in C Program - Break doesn\u2019t have semi colon (Semi Colon missing in break command)\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wikitechy.com\/interview-questions\/c\/what-is-the-output-of-this-c-code\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"What is the output of this C code ? - Recursive Function in C Program\" \/>\n<meta property=\"og:description\" content=\"What is the output of this C code ? - Recursive Function in C Program - Break doesn\u2019t have semi colon (Semi Colon missing in break command)\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wikitechy.com\/interview-questions\/c\/what-is-the-output-of-this-c-code\/\" \/>\n<meta property=\"og:site_name\" content=\"Wikitechy\" \/>\n<meta property=\"article:published_time\" content=\"2021-07-12T21:16:29+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2021-09-14T05:50:37+00:00\" \/>\n<meta name=\"author\" content=\"Editor\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Editor\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.wikitechy.com\\\/interview-questions\\\/c\\\/what-is-the-output-of-this-c-code\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.wikitechy.com\\\/interview-questions\\\/c\\\/what-is-the-output-of-this-c-code\\\/\"},\"author\":{\"name\":\"Editor\",\"@id\":\"https:\\\/\\\/www.wikitechy.com\\\/interview-questions\\\/#\\\/schema\\\/person\\\/4d5a581fb5470d1560324bddc5e8b757\"},\"headline\":\"What is the output of this C code ?\",\"datePublished\":\"2021-07-12T21:16:29+00:00\",\"dateModified\":\"2021-09-14T05:50:37+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.wikitechy.com\\\/interview-questions\\\/c\\\/what-is-the-output-of-this-c-code\\\/\"},\"wordCount\":99,\"commentCount\":0,\"keywords\":[\"Accentur interview questions and answers\",\"algorithm for switch case in c\",\"Applied Materials interview questions and answers\",\"Asian Paints Ltd. interview questions and answers\",\"Bosch India Software interview questions and answers\",\"c program for switch case using function\",\"C programming switch case examples\",\"C programming switch case Examples\\\/Programs\",\"C programming switch case Programs\",\"C switch case Statement\",\"Capgemini interview questions and answers\",\"CASTING NETWORKS INDIA PVT LIMITED interview questions and answers\",\"CGI Group Inc interview questions and answers\",\"Chetu interview questions and answers\",\"Ciena Corporation interview questions and answers\",\"Collabera Technologies interview questions and answers\",\"Dell International Services India Pvt Ltd interview questions and answers\",\"DHFL Pramerica Life Insurance Company Ltd interview questions and answers\",\"Elico HealthCare Services Ltd interview questions and answers\",\"Flipkart interview questions and answers\",\"HCL Technol interview questions and answers\",\"How does the switch and break work in C\",\"IBM interview questions and answers\",\"Indecomm Global Services interview questions and answers\",\"Java switch Statement\",\"Mavenir interview questions and answers\",\"Mphasis interview questions and answers\",\"NetApp interview questions and answers\",\"Oracle Corporation interview questions and answers\",\"PeopleStrong interview questions and answers\",\"Program for Switch Case with and without break statement\",\"R Systems interview questions and answers\",\"Raqmiyat Information Technologies Pvt Ltd interview questions and answers\",\"Reliance Industries Ltd interview questions and answers\",\"SAP Labs India Pvt Ltd interview questions and answers\",\"switch case\",\"switch case c\",\"switch case example in c\",\"switch case exercises in c\",\"switch case in c programming examples\",\"switch case in c programming questions\",\"switch case program in c\",\"switch case statement in C Programming\",\"switch caseswitch case statement in C Programming\",\"switch statement in c++\",\"Tata AIA Life Insurance interview questions and answers\",\"Tech Mahindr interview questions and answers\",\"The Linde Group interview questions and answers\",\"What is switch condition\",\"while c programming\"],\"articleSection\":[\"C\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/www.wikitechy.com\\\/interview-questions\\\/c\\\/what-is-the-output-of-this-c-code\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.wikitechy.com\\\/interview-questions\\\/c\\\/what-is-the-output-of-this-c-code\\\/\",\"url\":\"https:\\\/\\\/www.wikitechy.com\\\/interview-questions\\\/c\\\/what-is-the-output-of-this-c-code\\\/\",\"name\":\"What is the output of this C code ? - Recursive Function in C Program\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.wikitechy.com\\\/interview-questions\\\/#website\"},\"datePublished\":\"2021-07-12T21:16:29+00:00\",\"dateModified\":\"2021-09-14T05:50:37+00:00\",\"author\":{\"@id\":\"https:\\\/\\\/www.wikitechy.com\\\/interview-questions\\\/#\\\/schema\\\/person\\\/4d5a581fb5470d1560324bddc5e8b757\"},\"description\":\"What is the output of this C code ? - Recursive Function in C Program - Break doesn\u2019t have semi colon (Semi Colon missing in break command)\",\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.wikitechy.com\\\/interview-questions\\\/c\\\/what-is-the-output-of-this-c-code\\\/\"]}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.wikitechy.com\\\/interview-questions\\\/#website\",\"url\":\"https:\\\/\\\/www.wikitechy.com\\\/interview-questions\\\/\",\"name\":\"Wikitechy\",\"description\":\"Interview Questions\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.wikitechy.com\\\/interview-questions\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.wikitechy.com\\\/interview-questions\\\/#\\\/schema\\\/person\\\/4d5a581fb5470d1560324bddc5e8b757\",\"name\":\"Editor\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/e9531079fe7e07841b7b156c04d65e5f39d4adfd18b6ffe3edfff8ca5aab85b5?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/e9531079fe7e07841b7b156c04d65e5f39d4adfd18b6ffe3edfff8ca5aab85b5?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/e9531079fe7e07841b7b156c04d65e5f39d4adfd18b6ffe3edfff8ca5aab85b5?s=96&d=mm&r=g\",\"caption\":\"Editor\"},\"url\":\"https:\\\/\\\/www.wikitechy.com\\\/interview-questions\\\/author\\\/editor\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"What is the output of this C code ? - Recursive Function in C Program","description":"What is the output of this C code ? - Recursive Function in C Program - Break doesn\u2019t have semi colon (Semi Colon missing in break command)","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:\/\/www.wikitechy.com\/interview-questions\/c\/what-is-the-output-of-this-c-code\/","og_locale":"en_US","og_type":"article","og_title":"What is the output of this C code ? - Recursive Function in C Program","og_description":"What is the output of this C code ? - Recursive Function in C Program - Break doesn\u2019t have semi colon (Semi Colon missing in break command)","og_url":"https:\/\/www.wikitechy.com\/interview-questions\/c\/what-is-the-output-of-this-c-code\/","og_site_name":"Wikitechy","article_published_time":"2021-07-12T21:16:29+00:00","article_modified_time":"2021-09-14T05:50:37+00:00","author":"Editor","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Editor","Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.wikitechy.com\/interview-questions\/c\/what-is-the-output-of-this-c-code\/#article","isPartOf":{"@id":"https:\/\/www.wikitechy.com\/interview-questions\/c\/what-is-the-output-of-this-c-code\/"},"author":{"name":"Editor","@id":"https:\/\/www.wikitechy.com\/interview-questions\/#\/schema\/person\/4d5a581fb5470d1560324bddc5e8b757"},"headline":"What is the output of this C code ?","datePublished":"2021-07-12T21:16:29+00:00","dateModified":"2021-09-14T05:50:37+00:00","mainEntityOfPage":{"@id":"https:\/\/www.wikitechy.com\/interview-questions\/c\/what-is-the-output-of-this-c-code\/"},"wordCount":99,"commentCount":0,"keywords":["Accentur interview questions and answers","algorithm for switch case in c","Applied Materials interview questions and answers","Asian Paints Ltd. interview questions and answers","Bosch India Software interview questions and answers","c program for switch case using function","C programming switch case examples","C programming switch case Examples\/Programs","C programming switch case Programs","C switch case Statement","Capgemini interview questions and answers","CASTING NETWORKS INDIA PVT LIMITED interview questions and answers","CGI Group Inc interview questions and answers","Chetu interview questions and answers","Ciena Corporation interview questions and answers","Collabera Technologies interview questions and answers","Dell International Services India Pvt Ltd interview questions and answers","DHFL Pramerica Life Insurance Company Ltd interview questions and answers","Elico HealthCare Services Ltd interview questions and answers","Flipkart interview questions and answers","HCL Technol interview questions and answers","How does the switch and break work in C","IBM interview questions and answers","Indecomm Global Services interview questions and answers","Java switch Statement","Mavenir interview questions and answers","Mphasis interview questions and answers","NetApp interview questions and answers","Oracle Corporation interview questions and answers","PeopleStrong interview questions and answers","Program for Switch Case with and without break statement","R Systems interview questions and answers","Raqmiyat Information Technologies Pvt Ltd interview questions and answers","Reliance Industries Ltd interview questions and answers","SAP Labs India Pvt Ltd interview questions and answers","switch case","switch case c","switch case example in c","switch case exercises in c","switch case in c programming examples","switch case in c programming questions","switch case program in c","switch case statement in C Programming","switch caseswitch case statement in C Programming","switch statement in c++","Tata AIA Life Insurance interview questions and answers","Tech Mahindr interview questions and answers","The Linde Group interview questions and answers","What is switch condition","while c programming"],"articleSection":["C"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.wikitechy.com\/interview-questions\/c\/what-is-the-output-of-this-c-code\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.wikitechy.com\/interview-questions\/c\/what-is-the-output-of-this-c-code\/","url":"https:\/\/www.wikitechy.com\/interview-questions\/c\/what-is-the-output-of-this-c-code\/","name":"What is the output of this C code ? - Recursive Function in C Program","isPartOf":{"@id":"https:\/\/www.wikitechy.com\/interview-questions\/#website"},"datePublished":"2021-07-12T21:16:29+00:00","dateModified":"2021-09-14T05:50:37+00:00","author":{"@id":"https:\/\/www.wikitechy.com\/interview-questions\/#\/schema\/person\/4d5a581fb5470d1560324bddc5e8b757"},"description":"What is the output of this C code ? - Recursive Function in C Program - Break doesn\u2019t have semi colon (Semi Colon missing in break command)","inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wikitechy.com\/interview-questions\/c\/what-is-the-output-of-this-c-code\/"]}]},{"@type":"WebSite","@id":"https:\/\/www.wikitechy.com\/interview-questions\/#website","url":"https:\/\/www.wikitechy.com\/interview-questions\/","name":"Wikitechy","description":"Interview Questions","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wikitechy.com\/interview-questions\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.wikitechy.com\/interview-questions\/#\/schema\/person\/4d5a581fb5470d1560324bddc5e8b757","name":"Editor","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/e9531079fe7e07841b7b156c04d65e5f39d4adfd18b6ffe3edfff8ca5aab85b5?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/e9531079fe7e07841b7b156c04d65e5f39d4adfd18b6ffe3edfff8ca5aab85b5?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/e9531079fe7e07841b7b156c04d65e5f39d4adfd18b6ffe3edfff8ca5aab85b5?s=96&d=mm&r=g","caption":"Editor"},"url":"https:\/\/www.wikitechy.com\/interview-questions\/author\/editor\/"}]}},"_links":{"self":[{"href":"https:\/\/www.wikitechy.com\/interview-questions\/wp-json\/wp\/v2\/posts\/341","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wikitechy.com\/interview-questions\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wikitechy.com\/interview-questions\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wikitechy.com\/interview-questions\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wikitechy.com\/interview-questions\/wp-json\/wp\/v2\/comments?post=341"}],"version-history":[{"count":2,"href":"https:\/\/www.wikitechy.com\/interview-questions\/wp-json\/wp\/v2\/posts\/341\/revisions"}],"predecessor-version":[{"id":3640,"href":"https:\/\/www.wikitechy.com\/interview-questions\/wp-json\/wp\/v2\/posts\/341\/revisions\/3640"}],"wp:attachment":[{"href":"https:\/\/www.wikitechy.com\/interview-questions\/wp-json\/wp\/v2\/media?parent=341"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wikitechy.com\/interview-questions\/wp-json\/wp\/v2\/categories?post=341"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wikitechy.com\/interview-questions\/wp-json\/wp\/v2\/tags?post=341"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}