I need help in writing this code in C++. how can you write this type of progam ?
ID: 3758503 • Letter: I
Question
I need help in writing this code in C++. how can you write this type of progam ?
Write a function that dynamically allocates an array of integers. The function should accept an integer argument indicating the number of elements to allocate. The function should return a pointer to the array.
Write a function to fill an array with random integers.
Write a function that writes an array's contents to the standard output stream.
No global variables
Use default_random_engine and uniform_int_distribution to generate the random integers
Explanation / Answer
#include #include using namespace std; int *getArray(int); int calAverage(int t, int a,int s[]); int main() { int *score, total=0, average, howmany, numStudent, i=0,h=0; coutRelated Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.