Question: C++ STL Algorithms Lab 1 1. Write a function that checks to see if a value is less than 50. Use the function to find
C++
STL Algorithms Lab 1 1. Write a function that checks to see if a value is less than 50. Use the function to find the first value in a vector that is less than 50. 2. Rewrite Problem 1 using an anonymous function rather than a function. 3. Write a function that checks to see if a value is even. Use the function to count the number of even values in a randomly generated vector of integers. 4. Rewrite Problem 3 using an anonymous function. 5. Using the vector from problems 3 and 4, write a program that removes all the odd values from the vector using a predicate function. 6. Rewrite Problem 5 using an anonymous function.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
