Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

I have 2 C++ files I'm trying to compile and link but I keep getting error messages. For the first cpp file I get 6

I have 2 C++ files I'm trying to compile and link but I keep getting error messages.

For the first cpp file I get 6 of these when compiling:

warning: format specifies type 'unsigned int' but the argument has type 'int *' [-Wformat]

printf(" &cflag = \t %8x ", &cflag);

image text in transcribed

#include extern int gcount; void swapper (int & fnum, int &snum) /in order to perform I/0 */ 3 4 5 /* declaration of the variable gcount* static int cflag=0; int temp; output the addresses of the static local variable of swapper cflag &c flag); 10 11 printf(" &Cflag = \t %8x ", 12 13 * output the addresses of the local variables and parameters of swapper fnum, snum, and temp- \t printf (" &fnum = \t %8x &snum = \t %8x &temp %8x ", &fnum, &snum &temp) ; , 15 16 17 18 19Y 20 21 cflag+ if (fnum> snum) /I to count the number of times this function has been called so far gcount ++; temp = fnum; fnum = snum; snum = temp ; 23 24 25 26 printf (" so far, function swapper has been called :\t times" , cflag); 28 29 30 31 32 int express (int num1, int num2) output the addresses of the parameters of function express, num1 and num2 &num2); printf(" express: \t &num1-\t return (2 num1 -num2); %8x express: \t &num2 \t %8x", &nun1

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

Databases Illuminated

Authors: Catherine M. Ricardo

1st Edition

0763733148, 978-0763733148

More Books

Students also viewed these Databases questions

Question

2.1 Discuss what ethics means and the sources of ethical guidance.

Answered: 1 week ago

Question

8 What personal development is elearning good at providing?

Answered: 1 week ago

Question

7 What are the principles of action learning?

Answered: 1 week ago