<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>if else program in c - Wikitechy</title>
	<atom:link href="https://www.wikitechy.com/interview-questions/tag/if-else-program-in-c/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.wikitechy.com/interview-questions/tag/if-else-program-in-c/</link>
	<description>Interview Questions</description>
	<lastBuildDate>Mon, 03 Oct 2022 10:40:19 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>

<image>
	<url>https://www.wikitechy.com/interview-questions/wp-content/uploads/2025/10/cropped-wikitechy-icon-32x32.png</url>
	<title>if else program in c - Wikitechy</title>
	<link>https://www.wikitechy.com/interview-questions/tag/if-else-program-in-c/</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Explain IF-Else Statement in C Language ?</title>
		<link>https://www.wikitechy.com/interview-questions/c/explain-if-else-statement-in-c-language/</link>
					<comments>https://www.wikitechy.com/interview-questions/c/explain-if-else-statement-in-c-language/#respond</comments>
		
		<dc:creator><![CDATA[webmaster]]></dc:creator>
		<pubDate>Mon, 03 Oct 2022 10:08:04 +0000</pubDate>
				<category><![CDATA[C]]></category>
		<category><![CDATA[c conditional statement]]></category>
		<category><![CDATA[c if else statement]]></category>
		<category><![CDATA[c if..else]]></category>
		<category><![CDATA[explain if-else statement with suitable example]]></category>
		<category><![CDATA[how to use if-else statements in the c]]></category>
		<category><![CDATA[if else program in c]]></category>
		<category><![CDATA[if else statement in c]]></category>
		<category><![CDATA[if statement example]]></category>
		<category><![CDATA[if statement in c example]]></category>
		<category><![CDATA[if-else statement in c programming]]></category>
		<category><![CDATA[if..else statement syntax]]></category>
		<category><![CDATA[nested if-else statement in c example]]></category>
		<guid isPermaLink="false">https://www.wikitechy.com/interview-questions/?p=4922</guid>

					<description><![CDATA[If statement in C is known as a decision-making statement. It makes a decision based on the condition given. It is followed by an optional else statement. The block of codes inside the if statement is executed only if the given condition is true. Codes inside the curly braces are skipped if the condition evaluates [&#8230;]]]></description>
										<content:encoded><![CDATA[<ul>
<li>If statement in C is known as a decision-making statement.</li>
<li>It makes a decision based on the condition given.</li>
<li>It is followed by an optional else statement.</li>
<li>The block of codes inside the if statement is executed only if the given condition is true.</li>
<li>Codes inside the curly braces are skipped if the condition evaluates to false, and the code after the if statements are executed.</li>
<li>Code inside parenthesis of the if statement is true, everything within the curly braces is executed.</li>
<li>If condition true evaluates to true, code runs the printf execution.</li>
</ul>
<h2 id="syntax">Syntax</h2>
<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">if (testCondition) {<br/>   // statements<br/>}</code></pre> </div>
<h2 id="sample-code">Sample Code</h2>
<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">#include <stdio.h><br/>#include <stdbool.h><br/><br/>int main(void) {<br/>    if(true) {<br/>        printf(&quot;Statement is True!\n&quot;);<br/>    }<br/><br/>    return 0;<br/>}</code></pre> </div>
<h2 id="output">Output</h2>
<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">Statement is True.</code></pre> </div>
<h3 id="if-else-statements">if..else statements</h3>
<ul>
<li>In an ..else statement, code inside the brackets is executed only if the statement condition evaluates to true.</li>
<li>If the condition in the if statement evaluates to false, the code inside the else statement is executed.</li>
</ul>
<p><img fetchpriority="high" decoding="async" class="alignnone size-full wp-image-4926 aligncenter" src="https://www.wikitechy.com/interview-questions/wp-content/uploads/2022/10/if_else_statement.png" alt="" width="251" height="321" srcset="https://www.wikitechy.com/interview-questions/wp-content/uploads/2022/10/if_else_statement.png 251w, https://www.wikitechy.com/interview-questions/wp-content/uploads/2022/10/if_else_statement-235x300.png 235w" sizes="(max-width: 251px) 100vw, 251px" /></p>
<p> </p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.wikitechy.com/interview-questions/c/explain-if-else-statement-in-c-language/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>What is the output of this C code ? &#124; Recursion Program in C &#124; Recursion in C</title>
		<link>https://www.wikitechy.com/interview-questions/recursion-and-iteration/what-is-the-output-of-this-c-code-recursion-program-in-c-recursion-in-c/</link>
					<comments>https://www.wikitechy.com/interview-questions/recursion-and-iteration/what-is-the-output-of-this-c-code-recursion-program-in-c-recursion-in-c/#respond</comments>
		
		<dc:creator><![CDATA[Editor]]></dc:creator>
		<pubDate>Sat, 28 Aug 2021 17:26:53 +0000</pubDate>
				<category><![CDATA[Recursion and Iteration]]></category>
		<category><![CDATA[c functions list]]></category>
		<category><![CDATA[c programming functions exercises]]></category>
		<category><![CDATA[c programming if else example]]></category>
		<category><![CDATA[c programming if else exercises]]></category>
		<category><![CDATA[c++ if else practice problems]]></category>
		<category><![CDATA[else if ladder in c flowchart]]></category>
		<category><![CDATA[else if statement c programming]]></category>
		<category><![CDATA[function call in c]]></category>
		<category><![CDATA[function declaration in c]]></category>
		<category><![CDATA[functions in c programming with examples]]></category>
		<category><![CDATA[if else c]]></category>
		<category><![CDATA[if else if]]></category>
		<category><![CDATA[if else if ladder example in java]]></category>
		<category><![CDATA[if else if ladder in c++]]></category>
		<category><![CDATA[if else ladder in java]]></category>
		<category><![CDATA[if else program in c]]></category>
		<category><![CDATA[if else statement]]></category>
		<category><![CDATA[if else statement c++]]></category>
		<category><![CDATA[if else statement in c]]></category>
		<category><![CDATA[if else statement java]]></category>
		<category><![CDATA[nested if else c++]]></category>
		<category><![CDATA[nested if else in c programming examples]]></category>
		<category><![CDATA[nested if else in java]]></category>
		<category><![CDATA[syntax of function in c]]></category>
		<category><![CDATA[TCS Ninja Coding Questions with Answers | TCS Ninja Coding Questions 2021 | TCS Ninja Programming MCQ Questions]]></category>
		<category><![CDATA[types of functions in c]]></category>
		<category><![CDATA[types of functions in cuser defined functions in c]]></category>
		<category><![CDATA[user defined functions in c]]></category>
		<guid isPermaLink="false">https://www.wikitechy.com/interview-questions/?p=2653</guid>

					<description><![CDATA[Answer : D. This code will generate an error.]]></description>
										<content:encoded><![CDATA[<div class="TextHeading">
<div class="hddn">
<p class="color-pink">What is the output of this C code ?</p>
<div class="CodeContent">
<div class="hddn">
<figure class="highlight">
<pre><code class="hljs bash" data-lang=""><span class="nt">Function <span class="hljs-function"><span class="hljs-title">main</span></span>() {
  Integer i = <span class="hljs-number">0.7</span> Static <span class="hljs-built_in">float</span> m = <span class="hljs-number">0.7</span>
  If(m equals i)
  Print(“We are equal”)
  Else
  If(m > i)
  Print(“I am greater”)
  Else
  Print(“I am lesser”)
}</span></code></pre>
</figure>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<p>A. We are equal.</p>
</div>
<div class="col-sm-6">
<p>B. I am greater.</p>
</div>
<div class="col-sm-6">
<p>C. I am lesser.</p>
</div>
<div class="col-sm-6">
<p>D. This code will generate an error.</p>
</div>
</div>
</div>
</div>
<h3 id="answer-d-this-code-will-generate-an-error"><b>Answer : </b>D. This code will generate an error.</h3>
<div class="subheading">
<h2 id="explanation">Explanation:</h2>
</div>
<div class="Content">
<div class="hddn">
<ul>
<li>Two different <a href="https://www.wikitechy.com/tutorials/c-programming/c-data-type" target="_blank" rel="noopener">data types</a> cannot be linked with each other without <a href="https://www.wikitechy.com/tutorials/c-programming/typecasting-in-c" target="_blank" rel="noopener">type-casting</a>.</li>
</ul>
</div>
</div>
]]></content:encoded>
					
					<wfw:commentRss>https://www.wikitechy.com/interview-questions/recursion-and-iteration/what-is-the-output-of-this-c-code-recursion-program-in-c-recursion-in-c/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
