Answer to Question #34777 in C++ for Tawanna

Question #34777
I keep getting an error in my program:
#include< stdio.h >

void main()

{

double r=0.05;

int distance;

double R,i;

double power=500;

int v1=100,v2=200;

//calculating powerloss at v1=100

printf("\nPower loss at 100v");

for(distance=20;distance < =100;distance=distance+10)

{

R=distance*r;

i=power/v1;

double powerloss=(i*i)*R;

printf(" \nPower loss at %d distance is%f",distance,powerloss);

}

printf("\nPower loss at 200v");

for(distance=20;distance< =100;distance=distance+10)

{

R=distance*r;

i=power/v1;

double powerloss=(i*i)*R;

printf(" \nPower loss at %d distance is%f",distance,powerloss);

}

}
1
Expert's answer
2013-10-02T09:09:38-0400
The answer to the question is available in the PDF file https://www.assignmentexpert.com/https://www.assignmentexpert.com/homework-answers/programming-answer-34777.pdf

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
APPROVED BY CLIENTS