<?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>Convert Numeric To String &#8211; Sibeesh Passion</title>
	<atom:link href="https://sibeeshpassion.com/tag/convert-numeric-to-string/feed/" rel="self" type="application/rss+xml" />
	<link>https://sibeeshpassion.com</link>
	<description>My passion towards life</description>
	<lastBuildDate>Wed, 02 Jun 2021 15:17:33 +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>/wp-content/uploads/2017/04/Sibeesh_Passion_Logo_Small.png</url>
	<title>Convert Numeric To String &#8211; Sibeesh Passion</title>
	<link>https://sibeeshpassion.com</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Convert Numeric Number to String in C#</title>
		<link>https://sibeeshpassion.com/convert-numeric-number-to-string-in-c/</link>
					<comments>https://sibeeshpassion.com/convert-numeric-number-to-string-in-c/#disqus_thread</comments>
		
		<dc:creator><![CDATA[SibeeshVenu]]></dc:creator>
		<pubDate>Sun, 31 May 2015 13:09:16 +0000</pubDate>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Blog]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Convert Numeric To String]]></category>
		<category><![CDATA[CSarp]]></category>
		<category><![CDATA[Numeric to string]]></category>
		<guid isPermaLink="false">https://sibeeshpassion.com/?p=2911</guid>

					<description><![CDATA[Hi All, This program is returning output as string, lets go to an example. Such as, if you enter a number 19, then this program will return &#8220;Nineteen&#8221;. So shall we do it???? [csharp] using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ConvertNumericToString { class Program { static void Main(string[] args) { do { Console.WriteLine(&#34;Please enter the number..&#34;); int intNum = Convert.ToInt32(Console.ReadLine()); Console.WriteLine(CheckAndDisplayString(intNum)); Console.WriteLine(&#34;Do you want to continue ..Y/N?&#34;); } while (Console.ReadLine().ToLower() == &#34;y&#34;); Console.ReadLine(); } private static string CheckAndDisplayString(int intNum) { try { var str1To19 = new string[] { &#34;zero&#34;, &#34;one&#34;, &#34;two&#34;, &#34;three&#34;, &#34;four&#34;, &#34;five&#34;, &#34;six&#34;, &#34;seven&#34;, &#34;eight&#34;, [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>Hi All,</p>
<p>This program is returning output as string, lets go to an example. Such as, if you enter a number 19, then this program will return &#8220;Nineteen&#8221;. So shall we do it????<br />
[csharp]<br />
using System;<br />
using System.Collections.Generic;<br />
using System.Linq;<br />
using System.Text;  </p>
<p>namespace ConvertNumericToString<br />
{<br />
    class Program<br />
    {<br />
        static void Main(string[] args)<br />
        {<br />
           do<br />
            {<br />
                Console.WriteLine(&quot;Please enter the number..&quot;);<br />
                int intNum = Convert.ToInt32(Console.ReadLine());<br />
                Console.WriteLine(CheckAndDisplayString(intNum));<br />
                Console.WriteLine(&quot;Do you want to continue ..Y/N?&quot;);  </p>
<p>            } while (Console.ReadLine().ToLower() == &quot;y&quot;);<br />
            Console.ReadLine();<br />
        }  </p>
<p>        private static string CheckAndDisplayString(int intNum)<br />
        {<br />
            try<br />
            {<br />
                var str1To19 = new string[] { &quot;zero&quot;, &quot;one&quot;, &quot;two&quot;,<br />
                &quot;three&quot;, &quot;four&quot;, &quot;five&quot;, &quot;six&quot;,<br />
                &quot;seven&quot;, &quot;eight&quot;, &quot;nine&quot;, &quot;ten&quot;,<br />
                &quot;eleven&quot;, &quot;twelve&quot;,  &quot;thirteen&quot;,<br />
                &quot;fourteen&quot;, &quot;fifteen&quot;, &quot;sixteen&quot;,  &quot;seventeen&quot;,<br />
                &quot;eighteen&quot;, &quot;nineteen&quot;};<br />
                var strMultipleOfTen = new string[] { &quot;twenty&quot;, &quot;thirty&quot;,<br />
                &quot;forty&quot;, &quot;fifty&quot;, &quot;sixty&quot;, &quot;seventy&quot;,<br />
                &quot;eighty&quot;, &quot;ninety&quot; };<br />
                //If the Number is zero return null<br />
                if (intNum == 0)<br />
                    return &quot;zero&quot;;<br />
                //check the 100 digit<br />
                string strResult = &quot;&quot;;<br />
                int intDigit;<br />
                if (intNum &gt; 100)<br />
                {<br />
                    intDigit = intNum / 100;<br />
                    intNum = intNum % 100;<br />
                    strResult = str1To19[intDigit] + &quot;hundred&quot;;<br />
                }<br />
                if (intNum == 0)<br />
                    return strResult.Trim();<br />
                if (intNum &lt; 20)<br />
                    strResult += &quot; &quot; + str1To19[intNum];<br />
                else<br />
                {<br />
                    //handles 10 digit<br />
                    intDigit = intNum / 10;<br />
                    intNum = intNum % 10;<br />
                    strResult += &quot; &quot; + strMultipleOfTen[intDigit &#8211; 2];<br />
                    if (intNum &gt; 0)<br />
                        strResult += &quot; &quot; + str1To19[intNum];  </p>
<p>                }<br />
                return strResult;<br />
            }<br />
            catch<br />
            {<br />
                return &quot;The value you entered is not applicable..&quot;;<br />
            }<br />
        }<br />
    }<br />
}<br />
[/csharp]</p>
<p>See the output here:</p>
<p><img decoding="async" src="http://www.c-sharpcorner.com/UploadFile/BlogImages/11112014225442PM/output.jpg" alt="" /></p>
<p>Thank you 🙂</p>
]]></content:encoded>
					
					<wfw:commentRss>https://sibeeshpassion.com/convert-numeric-number-to-string-in-c/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
