1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
LekaFEV [45]
2 years ago
11

Define a function CoordTransform() that transforms the function's first two input parameters xVal and yVal into two output param

eters xValNew and yValNew. The function returns void. The transformation is new
Computers and Technology
1 answer:
Butoxors [25]2 years ago
4 0

Complete Question:

Define a function CoordTransform() that transforms its first two input parameters xVal and yVal into two output parameters xValNew and yValNew. The function returns void.

The transformation is new = (old + 1) * 2. Ex: If xVal = 3 and yVal = 4, then xValNew is 8 and yValNew is 10.

Answer:

The function written in C++ is as follows:

void CoordTransform(int xVal, int yVal) {

   int xValNew = (xVal + 1) * 2;

   int yValNew = (yVal + 1) * 2;

   cout<<"New x: "<<xValNew<<endl;

   cout<<"New y: "<<yValNew;

}

Explanation:

This line defines the function

void CoordTransform(int xVal, int yVal) {

This line declares and calculates xValNew

   int xValNew = (xVal + 1) * 2;

This line declares and calculates yValNew

   int yValNew = (yVal + 1) * 2;

This line prints xValNew

   cout<<"New x: "<<xValNew<<endl;

This line prints yValNew

   cout<<"New y: "<<yValNew;

}

<em>See attachment for complete program that includes the main method</em>

Download cpp
You might be interested in
The following slide was created as part of a presentation that trains new employees how to use the scheduling and calendar softw
brilliants [131]

it has animation, but it does not have multimedia and only has text and no images

8 0
3 years ago
Read 2 more answers
Please list ten things that you have learned an Excel Spreadsheet can do.
Furkat [3]

Certain things that MS excel can do are Tools, Calculators and Simulations, Dashboards and Reports with Charts, Automate Jobs with VBA macros, Solver Add-in & Statistical Analysis, Data Entry and Lists, Games in Excel

<u>Explanation:</u>

Microsoft Excel is a spreadsheet created by Microsoft for Windows, mac-OS, Android and iOS. It highlights computation, diagramming instruments, rotate tables, and a large scale programming language called Visual Basic for Applications.

Microsoft Excel is a spreadsheet program remembered for the Microsoft Office suite of utilization. Spreadsheets present tables of qualities orchestrated in lines and segments that can be controlled scientifically utilizing both essential and complex number-crunching tasks and capacities.

6 0
2 years ago
What service converts ip addresses into more recognizable alphanumeric names??
tresset_1 [31]
I think is DNS..........
6 0
3 years ago
Which statement best describes one reason why assembly language is easier
viktelen [127]

Answer:

machine language uses binary code and assembly language uses mnemonic codes to write a program.

Explanation:

In a nutshell, machine language uses binary code, which is almost impossible for humans to decipher, whereas assembly language uses mnemonic codes to write a program. Mnemonic codes make it simpler for humans to understand or remember something, and so make the language a bit easier for humans to use than machine code.

6 0
2 years ago
What is the importance of the international employment​
My name is Ann [436]

Answer:

People who went overseas to work can learn different skills and technologies which can be beneficial for the development of our own country.

7 0
3 years ago
Read 2 more answers
Other questions:
  • Book checkout scenario at a library: The Worker tells the System the identity of a patron who wishes to check out books. The Sys
    8·1 answer
  • Productivity can best be described as:
    5·2 answers
  • Effective presentations vary the color scheme on each slide.
    7·2 answers
  • An ____ is a collection of tools, features, and interfaces that enables users to add, update, manage, access, and analyze the co
    10·1 answer
  • When adopting the use of social media in emergency management, it is important to have
    10·1 answer
  • Why has base 2 been accepted and used as the basis for computing?​
    8·1 answer
  • If you are worried that team members will not keep sensitive information private, you could ask them to sign a ________ agreemen
    15·1 answer
  • Create a Python program that computes the cost of carpeting a room. Your program should prompt the user for the width and length
    10·1 answer
  • Select the correct answer.
    5·1 answer
  • Javier downloads an illustration from an online Image library and modifies it for his purposes. The illustration he downloads is
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!