Please answer it by C++ method...
Otherwise name a brainly teacher good in Computer...
Attachments:
Answers
Answered by
3
C++ Program to calculate distance :
// C++ Program to calculate distance
#include<iostream>
using namespace std;
// Function to calculate distance traveled
double cal_dis(double speed, double time)
{
cout << "\n Time(hr) : " << time ;
cout << "\n Speed(km / hr) : " << speed ;
return speed * time;
}
// Driver function
int main()
{
// Calling function cal_dis()
cout << "\n The calculated Distance(km) : "
<< cal_dis(70.0,5.0) << endl ;
return 0;
}
Output :
Time(hr) : 5
Speed(km / hr) : 70
The calculated Distance(km) : 350
Answered by
0
Explanation:
I hope it may help to you..
Attachments:
Similar questions
English,
3 months ago
Social Sciences,
3 months ago
English,
3 months ago
Science,
7 months ago
Business Studies,
7 months ago
Math,
10 months ago
CBSE BOARD X,
10 months ago