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
Lisa [10]
3 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 = (old + 1) * 2. Ex: If xVal = 3 and yVal = 4, then xValNew is 8 and yValNew is 10.
Computers and Technology
1 answer:
WARRIOR [948]3 years ago
6 0

Answer:

Check the explanation

Explanation:

#include <iostream>

using namespace std;

void CoordTransform(int x, int y, int& xValNew,int& yValNew){

  xValNew = (x+1)*2;

  yValNew = (y+1)*2;

}

int main() {

  int xValNew = 0;

  int yValNew = 0;

  CoordTransform(3, 4, xValNew, yValNew);

  cout << "(3, 4) becomes " << "(" << xValNew << ", " << yValNew << ")" << endl;

  return 0;

}

You might be interested in
Technician A states that a tap handle has a right-angled jaw that matches the squared end that all taps have. Technician B state
Elena L [17]

Answer:

Technician A and Technician B are correct

Explanation:

Based on the information provided within the question it can be said that both Technician A and Technician B are correct. A tap handle's right-angled jaw allows many different taps to be attached for different types of situation to more comfortably and conveniently handle that situation. Such as a T-shaped tap in order to cut a thread in an awkward space as Technician B has stated.

3 0
3 years ago
How do you print black and white on the ink Canon Pixma/TS3122?
Paha777 [63]

Answer:

If this printer can connect to a device wirelessly, then you can configure it through our mobile device. If not , try to click either the button above the yellow lights or below and see if that works.

5 0
3 years ago
Which of the following are NOT two of the best ways to StaySafe around electricity? A. Maintain a safe distance from overhead po
kherson [118]

The answer is option C: Use ground-fault circuit interrupters, and inspect extensions cords and portable tools.

Inspecting the extension cords needs to be done constantly, or there can be abrasions or cuts that won't be noticed. Option B remains one of the most important ways to be safe around electricity. Always wear non-conductive safety equipment, such as safety goggles or rubber gloves. You should also avoid touching exposed metal. Option C indicates one of the two ways that do not help you stay safe around electricity. A ground fault interrupter only works if there is a short circuit or a huge amount of energy going through that point and thus, will not effectively protect you from possible incidents with electricity.


3 0
3 years ago
Read 2 more answers
Assume that k corresponds to register $s0, n corresponds to register $s2 and the base of the array v is in $s1. What is the MIPS
BlackZzzverrR [31]

Answer:

hello your question lacks the C segment so here is the C segment

while ( k<n )

{v[k] = v[k+1];

     k = k+1; }

Answer : while:

   bge $s0, $s2, end   # while (k < n)

   addi $t0, $s0, 1    # $t0 = k+1

   sll $t0, $t0, 2     # making k+1 indexable

   add $t0, $t0, $s1   # $t0 = &v[k+1]

   lw $t0, 0($t0)      # $t0 = v[k+1]

   sll $t1, $s0, 2     # making k indexable

   add $t1, $t1, $s1   # $t1 = &v[k]

   sw $t0, 0($t1)      # v[k] = v[k+1]

   addi $s0, $s0, 1

   j while

end:

Explanation:

The MIPS assembly code corresponding to the C segment is

while:

   bge $s0, $s2, end   # while (k < n)

   addi $t0, $s0, 1    # $t0 = k+1

   sll $t0, $t0, 2     # making k+1 indexable

   add $t0, $t0, $s1   # $t0 = &v[k+1]

   lw $t0, 0($t0)      # $t0 = v[k+1]

   sll $t1, $s0, 2     # making k indexable

   add $t1, $t1, $s1   # $t1 = &v[k]

   sw $t0, 0($t1)      # v[k] = v[k+1]

   addi $s0, $s0, 1

   j while

end:

4 0
3 years ago
What does NIC stand for
AfilCa [17]
Network Interface Card
7 0
3 years ago
Read 2 more answers
Other questions:
  • Type the correct answer in the box.
    7·1 answer
  • Which of the following are features of the HTTPS protocol?
    6·1 answer
  • Traditional methods of business communication tend to mean paper-based messages such as formal letters, brochures, reports, prop
    10·1 answer
  • This diagram shows a number of computing devices connected to the Internet with each line representing a direct connection.
    8·1 answer
  • What are the advantages of using an external style sheet?
    9·1 answer
  • How can I, fill the application form for jobs. [such as Macdonal's jobs].?
    12·1 answer
  • CAN YOU PLEASE HELP WITH THIS DUE IN 10 MINUTES
    8·1 answer
  • Peer collaboration helps develop critical-thinking skills, which is the ability to
    9·2 answers
  • What is an a free open source content management system for publishing web content​
    8·1 answer
  • Normal view definition
    5·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!