Ok I need help with a program I need to make in programming class. I have most of it done already, but I'm missing something, if you guys could point me in the right direction. I have to do as follows:
I have to create a program that will calculate runner's time. Typical input would be as follows:
Runner number: 234
Mile times: 1 5:34.22
2 11:21.67
Finish time: 17:46.85
Typical output would be:
Runner number 234
Split one 5:34.22
Split two 5:47.45
Split three 6:25.18
Finish time 17:46.85
I got most of it done, but what I can't figure out is how to convert the input to the format it's in right here, with the colon and everything, when I run the program and get to that part it just messes up, and that's what I need help with. This is what I got so far:
//Manny Roldan#include #include #include int main(){ double time1, time2, time3; double split1, split2, split3; int rn; cout>rn; cout>time1; cout>time2; split1 = (time1-0); split2 = (time2-time1); split3 = (time3-time2); time3 = (time1+time2); cout<<"Runner Number"<I know I'm missing something, please help. Thanks in advance