C++
Please do not use global variables.
Function Name: formatTime
4 Formatting formatTime Takes one string parameter (duration) * Returns a formatted (HH:MM:SS) duration string Example parameter / return values: . 110054″ “11:00:54” . “145316” “14:53:16″ Show transcribed image text 4 Formatting formatTime Takes one string parameter (duration) * Returns a formatted (HH:MM:SS) duration string Example parameter / return values: . 110054” “11:00:54” . “145316” “14:53:16”
Answer
Explanation::
- Code in C++ is given below
- Please read comments for better understanding of the code
- Output is provided
OROR