No. It seems that you should learn and doing that homework by yourself could help you in that.
You have shown that you master copy-paste. Handing you any code is therefore detrimental to you.
You want "expain". Here is some:
* You have to think what logical steps are needed, in what specific order, to solve the problem
* You have to figure out, how to do those steps with programming language
Input
Each of the first two lines contains a bought string.
#include <iostream>
#include <cctype>
#include <limits>
int main()
{
std::cout << "Do you want someone to do all the work for you? ";
char answer{};
std::cin >> answer;
std::cin.ignore(std::numeric_limits<std::streamsize>::max(), '\n');
if (std::toupper(answer) == 'Y' ) { std::cout << "Post it in the Jobs section.\n"; }
else { std::cout << "Show what you have coded so far.\n"; }
std::cout << "Good luck.\n";
}