Write C++ programing

1- Write a C++ program that will ask the user to input a string.

  1. Yourprogramwilldecideifthatstringisapalindrome(itisastring that would read the same way forward and backward).You must use a bool function that would take a string parameter bool isPalindrome(string s){——}
  2. Ifitisnotaplaindromprintthestringandthebackwardstring separated by space.

2. Write a program that includes a function that takes 4 int parameters, doubles them and return the sum of the four numbers.

Don't use plagiarized sources. Get Your Custom Essay on
Write C++ programing
Just from $13/Page
Order Essay

3. Write a program that includes a function that would permanently reverse a string passed to it. Your function must be a void function. Hint: The string should be passed by reference.

4- Write a bool function isPrime(int n) that decides whether n is prime or not prime.
5- Use the function in #4 in a wrapper function that calls it – the wrapper function should call primeSequence that takes an int x and prints all the prime numbers up to x.

You should test all your functions by calling them from main and passing user input.

Still struggling to complete your homework?
Get instant homework help from our expert academic writers!