Skip to content

Problem 1 Write a program that Asks the user to enter a si

    Problem 1: Write a program that: Asks the user to enter a size of an arrayAsks the user to enter a certain number of integers, based on the entered array size, separated by spaceStores them using a pointer to a dynamically allocated array of integers. Then the program should print out the integers to the screen and print the average of even numbers and the average of odd numbers Note: you can have averageEven(double a[ ], int size) and averageOdd(double a[ ], int size) as two functions that you invoke in your main method. Average of even numbers is the sum of even numbers divided by the number of even numbers in the array. Problem 2: Consider the class Country: Private:string countryCode;int population;int callCode;Public:Country(string countryCode, int population, int callCode); string getCountryCode(); int getCallCode(); int getPopulation(); Write a program that: Asks the user to enter a number of countries he wants to enter the data forAsks the user to enter the details of each country in a line separated by spaces (country code, population, call code) and create a dynamically allocated instance of Country based on thatEnter each instance in a vector of Country*Sort the vector of Country* based on the populationDisplay the countries’ data in descending order of their population

    Do You Need A Similar Assignment Done For You From Scratch? We Have Qualified Writers To Help You. We Assure You An A+ Quality Paper That Is Free From Plagiarism. Order Now For An Amazing Discount!

    Very professional support! Highly recommended.


    Researched complicated topic and delivered report by the requested deadline. The paper is of a high standard reflecting careful research and clear assessments. I recommend

    Daria K


    It’s a 5 start for me. Excellent research and writing. The paper reflects a careful assessment of scientific information.



    With Gib’s reflection, they wrote a really specific essay. Very well written, containing all of the languages I required and excellent references. The writer follows my instructions and writes clearly in English.

    Mario G


    I am so grateful and I am 100% happy with your work.



    A fantastic piece of work 👏. The writer demonstrated full knowledge of the topic and applying the relevant provided material. Well done.