"Learning ANSI C" - Most popular high-level computer programming language

in GEMS4 years ago

enter image description here

<p dir="auto">Hello guys,<br /> How are you?<br /> After a very long period I just come back to my favourite blogging platform hive. I have a plan to start a basic tutorial on computer programming language "ANSI C" on hive, which I've already started on steemit platform. But, I want share my tutorial not only on steemit, but, also on hive community. So, I just started here-- <p dir="auto">Actually, "C" is the most popular & easy to learn, more efficient & fast, high-level computer programming language. If you learn "C" very well then you can do learn any programming language within one month. So, it's called "C" language is the base of all programming language. <p dir="auto"><strong>What is "C" ?<br /> "C" is the next & modified version of programming language "B". What is "B" ? "B" means "BCPL(Basic Combined Programming Language)" which was developed at Cambridge University in the year of 1960. Later in the year of 1972, "B" was heavily modified by Dennis Ritchie (a computer scientist worked at Bell Laboratories). Dennis Ritchie renamed this modified version of "B" to "C". <p dir="auto">Unlike many other languages "C" is completely machine independent; it means if you write a program in C for one computer, it'll be run on another computer on different OS(operating system) without any modification. "C" is not object-oriented language like "C++" is. It's called Procedural Oriented language. Actually, any program written in C is basically a set of functions which are defined in C library. <p dir="auto"><strong>What are we learning here? <h3>C Data Types, Variables & Constants, Keywords & Identifiers <h3>C Operators & Expressions <h3>Management of Input/Output (I/O) Operators <h3>Decision Making & Structuring <h3>Decision Making & Looping <h3>Functions Handling <h3>One-dimensional , Two-dimensional & Multi-dimensional Arrays <h3>Character Strings Handling <h3>Pointers <h3>File Handling & Operations <h3>Structures & Unions <h3>Dynamic Memory Allocation <h3>Preprocessor & Header Files <p dir="auto"><br /><br /> <strong>An Example of C Program<br /> Here I show you a simple program written in C language. In this program it calculates the sum of two integer numbers & show the result on the computer screen: <pre><code>/* Sample Program Written in ANSI C */ /* This program shows how to calculate summation of two integer numbers & show the result on the screen*/ /* Written by @royalmacro */ #include <stdio.h> #include <conio.h> void main() { int number1, number2, sum; /*variable deceleration*/ clrscr(); /*Clear the whole screen*/ printf("Enter Number-1: "); scanf("%d",&number1); /*number input*/ printf("Enter Number-2: "); scanf("%d",&number2); /*number input*/ sum=number1+number2; /*calculat summation*/ printf("%d is the summation of %d & %d",sum,number1,number2); getch(); /*wait until hit a key*/ } <p dir="auto"><br />After compiling & running this program it shows like below:<br /> Sample Window- <pre><code>Enter Number-1: 67 Enter Number-2: 33 100 is the summation of 67 & 33 <p dir="auto"><img src="https://images.hive.blog/768x0/https://i.imgur.com/jqH8yPl.png" alt="sample c program" srcset="https://images.hive.blog/768x0/https://i.imgur.com/jqH8yPl.png 1x, https://images.hive.blog/1536x0/https://i.imgur.com/jqH8yPl.png 2x" /> <p dir="auto"><br /><strong>Where I'll get C compiler ?<br /> There many C compilers available, one of them "Turbo C++ version 3" is most popular. To get this compiler for Windows 7/8/10 (for both 32-bit & 64-bit operating system) check this following website. It's absolutely free. <p dir="auto"><strong><a href="https://developerinsider.co/download-turbo-c-for-windows-7-8-8-1-and-windows-10-32-64-bit-full-screen/" target="_blank" rel="nofollow noreferrer noopener" title="This link will take you away from hive.blog" class="external_link">Download Turbo C++ for Windows 7, 8, 8.1 and Windows 10 (32-64 bit) with full/window screen mode and many more extra feature. <p dir="auto">If you do not want to download you can try online C compiler on tutorialspoint. <p dir="auto"><strong><a href="https://www.tutorialspoint.com/compile_c_online.php" target="_blank" rel="nofollow noreferrer noopener" title="This link will take you away from hive.blog" class="external_link">Compile and Execute C Online <p dir="auto">In the next episode we'll discuss about <strong>"Basic Structure of a C Program" <p dir="auto"><strong><em>[To be continued...] <h1> <p dir="auto"><i><span>N.B. This tutorial was also published on my steemit blog (ID <a href="/@royalmacro">@royalmacro)