UPDATED:

How To Make A Simple Calculator By C Happy Coding.......... Happy Coding.......... Happy Coding.......... Happy Coding.......... Happy Coding.......... Happy Coding.......... Happy Coding.......... Happy Coding.......... Happy Coding.......... Happy Coding.......... Happy Coding.......... Happy Coding.......... This blog is under construction!!!!
Namecheap.com

Friday, December 23, 2016

Differences between C and C ++

C ++ is a successor to C and was developed by Bjarne Stroustrup in AT & T-Labs. C ++ is down-compliant to C, which means that C programs can also be compiled with a C ++ compiler.

Theory and practice can be diverted here.
The programming language C has been standardized several times (see variants of the programming language C at Wikipedia), of which C ++ is based on the 1990 standard (C90, ISO / IEC 9899: 1990). C was expanded afterward. The following C standards (C95, C99) play a subordinate role in practice, but these extensions could not be considered in C ++.

On the other hand, extensions that brought C ++ (!) Found their way into C standards. Thus C ++ language elements were integrated into C.

In addition to the different standards, non-standard implementations of the C ++ compiler can also create problems.

However, what is complicated here is less dramatic in practice. I just want to point out that there is not always a 100% downward compatibility.

What to start with? C or C ++?


Basically: Both are possible. Beginning with C ++ is certainly more complex and time-consuming (time and patience problem) - because of the larger number of language elements.
We suggest you start with C

As mentioned above, C ++ is the "larger brother" of C, backward compatible with it (except for minor exceptions). All C language elements are also available under C ++. They are learning new things when switching to C ++, and C ++ offers better solutions (object-oriented programming). Conversely, if you first need to learn C ++, and then later you have to write a pure C program (which has to run on a "pure-breed" C compiler), you first have to learn what was not yet available in C.

If you primarily intend to program hardware or microcontrollers, also speaks more for pure C. C compilers, there are more platforms than C ++ compilers. For every exotic processor, there is usually a C compiler. And if not, then often remains more assembler.

If you are completely new to the programming (beginners), speak also a lot of a language with fewer language elements, in order to keep the learner motivated. Otherwise, the overview of the whole is often lost. Another point for C.

Thursday, June 2, 2016

How to find circle area using πr ² formula in C

πr² is a common formula to us.But can you find a circle area value by C?
if not,try this.It's help you to know how to find/print the value of a circle 
area in C programming language.


Code to print the value:


#include<stdio.h>

#define PI 3.1416

int main()
{
    float circle_area, r;

    printf("Enter the value of radius: \n");
    scanf("%f", &r);

    circle_area = PI *r * r;

    printf("The circle area is: %.2f\n", circle_area);


return 0;

}


OR,


#include<stdio.h>



int main()

{
    float circle_area, r, PI=3.1416;

    printf("Enter the value of radius: \n");

    scanf("%f", &r);

    circle_area = PI * r * r;


    printf("The circle area is: %.2f\n", circle_area);



return 0;


}


The Output is:




Face problems?No problem.You can share your problems by commenting below.or you can leave a massage us.Thank you.

make a currency converter By C programming language

We can make a simple currency converter by C programming language.

Lets see the code:

#include <stdio.h>
double convert(void);
int main(void){

    double taka;

    taka=convert();
    printf("In taka= %0.2lf\n",taka);

    return 0;
}

double convert(void)
{
    double dollars,multi_value;
    multi_value=80.0;

    printf("enter dollar amount: \n");
    scanf("%lf", &dollars);

    return dollars*multi_value;

}

Output:

It is really great.But if you face any problem or have any question,please comment below.

Thursday, May 26, 2016

How to make simple calculator by C

We are going to make a simple calculator by C.By this calculator we can do summation,subtraction,multiplication and division.Lets have a look to the program.


how to make a simple calculator by c
#include <stdio.h>
#include <conio.h>

int main()
{
    float a,b,sum,sub,mul,div;
    char ch;

    printf("Enter a number: \n");
    scanf("%f", &a);

    printf("Enter another number: \n");
    scanf("%f", &b);

    sum=a+b;
    sub=a-b;
    mul=a*b;
    div=a/b;

    printf("What do you want?\n");
    printf("a: summation.\t b: subtraction.\nc: multiplication.\t d: division.\n");

    scanf(" %c",&ch);

    if(ch == 'a')
    {

        printf("summation value: %.2f\n",sum);

    }
    else if(ch == 'b')
    {

        printf("subtraction value: %.2f\n",sub);

    }
       else if(ch == 'c')
    {

        printf("multiplication value: %.2f\n",mul);

    }
       else if(ch == 'd')
    {

        printf("division value: %.2f\n",div);

    }
    else
    {

        printf("something went wrong!!\n");
    }

    return 0;
    }


Now Try it by yourself.If you face any problem and you have any question regarding the program you can comment below.
Thank you.

Friday, March 4, 2016

Summation,Subtraction,Multiplication and Division by C

Now we are going to do summation with C.Write down the following program and compile it.Then see what happen.


Program Code


#include <stdio.h>
int main ()
{
    int a;
    int b;
    int sum;
    a = 50;
    b = 60;
    sum = a + b;
    printf("sum is %d",sum);
    return 0;
}





Program details:

At first we named three variables as our wish.I took a,b, and sum.Here i assigned 50 for a and 60 for b.sum= a+b means i assigned a value in sum which is equal to a+b.You already know about the printf function.Here it commanded to print the value of sum.

Work for you:

Now you have to do subtraction,multiplication and division following this program.When you done post your program in comment box here or in our facebook group Coder Mania BD.

## If you face any problem with C program join our facebook group C Clinic by Coder Mania BD to get solution.

Thanks for being with Coder Mania BD.

Namecheap.com

Popular Posts