subject
Engineering, 17.09.2019 20:00 Thania3902

All instructions are given in the form of comments in the file. you are to again run the file in both gcc and visual studio (2017 or 2015 version). observe the outputs and make changes as asked.#include #pragma warning(disable : 4996) // needed in vs// cse 240 fall 2018 homework 2 question 3 (25 points)// note: you may notice some warnings when you compile in gcc or vs, that is okay.#define positive_1(x) ((x > 0) ? x : 0)#define polynomial_2(a, b) (a*a + 2*a + 4*a*b - b*b)int function_1(int a, int b) {return (a*a + 2*a + 4*a*b - b*b); }(a) run this program in visual studio(vs) and then again in gcc. note the output values for function_1 and polynomial_2.void part2(int x, int y) {int x_copy = x, y_copy = y; printf("function_1(x, y) = %d \n polynomial_2(x, y) = %d \n\n", function_1(++x, ++y), polynomial_2(++x_copy, ++y_copy)); (b) correct the program so that function_1 and polynomial_2 produce same correct output of 371.

ansver
Answers: 2

Another question on Engineering

question
Engineering, 03.07.2019 14:10
Amass of m 1.5 kg of steam is contained in a closed rigid container. initially the pressure and temperature of the steam are: p 1.5 mpa and t 240°c (superheated state), respectively. then the temperature drops to t2= 100°c as the result of heat transfer to the surroundings. determine: a) quality of the steam at the end of the process, b) heat transfer with the surroundings. for: p1.5 mpa and t 240°c: enthalpy of superheated vapour is 2900 kj/kg, specific volume of superheated vapour is 0. 1483 m/kg, while for t 100°c: enthalpy of saturated liquid water is 419kj/kg, specific volume of saturated liquid water is 0.001043m/kg, enthalpy of saturated vapour is 2676 kj/kg, specific volume of saturated vapour is 1.672 m/kg and pressure is 0.1 mpa.
Answers: 3
question
Engineering, 04.07.2019 18:10
What difference(s) did you notice using a pneumatic circuit over hydraulic circuit.explain why the pneumatic piston stumbles when it hits an obstacle.
Answers: 2
question
Engineering, 04.07.2019 18:20
An engine runs on the ideal diesel cycle. the cycle has a compression ratio of 20 and a cutoff ratio of 2. the highest temperature in the cycle is 1200 k. if the heat into the system is 300 kj/kg of working fluid and using variable specific heats determine the work produced per mass of working fluid
Answers: 3
question
Engineering, 04.07.2019 19:10
Afoot bridge is made as a simple deck, 4 m long, with a cross section 2 m (wide) and 20 cm thick, and made of wood. the deck is supported at the two ends. the maximum load allowable on the bridge is 10 tons, provided it is uniformly distributed on the deck. to sense this load, a strain gauge is placed at the center of the bridge and its resistance is monitored. if the sensor has a nominal resistance of 350 s2 and a gauge factor of 3.6, what is the reading of the strain gauge at maximum load? the modulus of elasticity for the wood used in the construction is 10 gpa.
Answers: 2
You know the right answer?
All instructions are given in the form of comments in the file. you are to again run the file in bot...
Questions
question
Social Studies, 08.12.2020 20:30
question
SAT, 08.12.2020 20:30
question
Mathematics, 08.12.2020 20:30
question
Computers and Technology, 08.12.2020 20:30
question
Mathematics, 08.12.2020 20:30
Questions on the website: 13722359