1.Declare three variables as
int a,b,c;
2.Get the Input of two numbers of Integers from the user:
scanf("%d",&a);
scanf("%d",&b);
3.add a and b and store the result in c
4. print c
Chat with our AI personalities
a write the algorithm to concatenate two given string
1. High accuracy. Comparing to Basic Incremental algorithm (especially if the slope were > 1.) 2. High speed. Comparing to Digital Differenmtial algorithm. 3. Draws the line between any two points. Comparing to Basic Incremental algorithm which can't draw if x0 > x1 ( the format is: (x0, y0), (x1, y1). )
flow chart to swap two number
These two algorithms are almost completely different. The only real similarity is that they are each designed to use only integer addition/subtraction and multiplication, avoiding expensive division and floating point operations.
algorithm GCD (a, b) is:while (a b) doif a > b then a := a - b else b := b - aend whilereturn a