Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

please answer all the question Question 15 (5 points) code the function header named func01, returns a float, and has as parameters an three ints

please answer all the question

Question 15 (5 points)

code the function header named func01, returns a float, and has as parameters an three ints named x, y, and z and an integer pointer named px

Question 15 options:

void func01(int x, int y, int z, int*px)

float func01(int x, int y, int z, int* px)

float func01(int x, int y, int z, int px)

float func01(int x, int y, int z, float* px)

Question 16 (5 points)

the following function header

float func01(int x, int y, int z, int* px)

what is the statement that would be in the function that would add x, y, and z and put the sum to where px points to (the mail box)

Question 16 options:

px = x, y, z;

x + y + z = *px;

px = x + y + z;

*px = x + y + z;

Question 17 (5 points)given the following function header

float func01(int* px, int* py, int* pz)

what is the statement that would be in the function that would add what px points to to what py points to and put the sum where pz points to

Question 17 options:

*pz = *px + *py;

pz = px + py;

*pz = px + py;

*px + *py = *pz;

Question 18 (5 points)

assume you have coded an array of 10 characters named chArray and a character pointer named pch. which statement would make the pointer pch point to the first element of the array

Question 18 options:

*pch = chArray;

pch = chArray;

&pch = chArray[0];

chArray[0] = *pch;

Question 19 (5 points)

define an integer pointer named px and allocate memory to it

Question 19 options:

int* px = new int;

int px = new int;

*px = new int;

px = & new int;

Question 20 (5 points)

define an integer pointer named px, allocate memory to it and initialize the memory to 666

Question 20 options:

int* px = new int(666);

int* px = new int[666];

*px = new int * 666;

px = &666

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Intelligent Databases Technologies And Applications

Authors: Zongmin Ma

1st Edition

1599041219, 978-1599041216

Students also viewed these Databases questions