Answered step by step
Verified Expert Solution
Question
1 Approved Answer
C++ only Write a function that takes a pointer to an array of integers and return the count of positive numbers found in that array.
C++ only
Write a function that takes a pointer to an array of integers and return the count of positive numbers found in that array. int countPost(int *values, int size, Write a main program to test your function, you should ask the user for the size, read an array with given size using the teadArray function from the user and then print back to the user the number of positive values in your array that you found by calling the countPost function. A sample output is given below: Please enter the size: 10 Please enter 10 elements: 10 0 -4 -2 1 3 -6 7 -1 9 The count of positive values is : 6Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started