Computer Science, asked by maggie48, 1 year ago

write a program to display the equation of a line in the form ax+by=c for a=5,b=8,c=18​

Answers

Answered by bibona
5

Answer:

the above pic is the script.

Attachments:
Answered by lovingheart
36

A program to display the equation of a line:

#include<stdio.h>

#include <conio.h>

void main()

{  

int a=5,b=8,c=18;  

int x,y,z;  

clrscr();  

printf(“The Equation of line is\n”);  

printf(“%dX + %dY = %d”,a,b,c);

getch();  

}

In the above code, the value of a, b, and c are assigned as given in the question.  Header files are included to execute input output operations and also to clear the screen. clrscr() will clear the screen to display the fresh output. The equation is displayed using the final printf statement.

Similar questions