Question: Create function chunk(), which will pass as an argument std::vector of enumerate type with LEFT, RIGH and IDLE values. Function should return an std::vector with

Create function chunk(), which will pass as an argument std::vector of enumerate type with LEFT, RIGH and IDLE values. Function should return an std::vector with an array of 3 values of the same enumerate type. If the size of the vector is not divisible by 3 , fill the remaining elements with IDLE value so it will be. Create function effectively_idle() which can pass the result of chunk() function as an argument. Check if all of previously mentioned arrays of 3 elemnts are effectively idle (values in the arrays are (LEFT, RIGHT, IDLE) or (IDLE, IDLE, IDLE))
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
