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
ratelena [41]
3 years ago
13

Write a program, using the syntax of whatever language you like, that produces different behavior depending on whether pass-by-r

eference or pass-by-value-result is used in its parameter passing.
Computers and Technology
1 answer:
telo118 [61]3 years ago
7 0
```
#!/usr/local/bin/python3
 

def add2x( x ):
    print( "beginning of add2x, x = %d" % x )
    x += 1
    print( "end of add2x, x = %d" % x )

def add2y( y ):
    print( "beginning of add2y, y = %d" % y[ 0 ] )
    y[ 0 ] += 1
    print( "end of add2y, y = %d" % y[ 0 ] )

if( __name__ == "__main__" ):
    x = [ 5 ]
    y = [ 5 ]

    print( "before add2x, x = %d" % x[ 0 ] )
    add2x( x[ 0 ] )
    print( "after add2x, x = %d\n" % x[ 0 ] )

    print( "before add2y, y = %d" % y[ 0 ] )
    add2y( y )
    print( "after add2y, y = %d" % y[ 0 ] )
```



You might be interested in
Sandi wants to check the average grades in her classroom. Which loop or algorithm should she use?
tatyana61 [14]

Answer:

D

Explanation:

Maximum-minimum algorithm will help Sandi check the average grades in her classroom.

Have a great day

8 0
3 years ago
What is the purpose of a register in a CPU? Describe three types of registers.
Ganezh [65]

Answer:

I hope this answer is correct

Explanation:

Internal registers include the instruction register (IR), memory buffer register (MBR), memory data register (MDR), and memory address register (MAR). The instruction register fetches instructions from the program counter (PC) and holds each instruction as it is executed by the processor.

5 0
3 years ago
The amount of detail an image can hold is called it’s
kogti [31]

the amount of detail an image can hold is called it’s

resolution

7 0
3 years ago
One difference between multi-tasking using fork() versus using threads is that there is race condition among threads due to shar
MAXImum [283]

Answer:

vnn

Explanation:

7 0
3 years ago
Read 2 more answers
A(n) _________ Web page displays customized content in response to keyboard or mouse actions or based on information supplied di
RoseWind [281]

Answer:

dynamic

Explanation:

A dynamic web page serves out varied material to various visitors while keeping the same layout and appearance. These pages, which are often built in AJAX, ASP, or ASP.NET, require longer to render than plain static sites. They are commonly used to display data that updates regularly, such as weather forecast or market prices.

Dynamic web pages often incorporate software applications for various services and need server-side resources such as databases. A database enables the page builder to divide the design of the website from the content that will be presented to users. When they post material to the database, the website retrieves it in response to a user request.

5 0
2 years ago
Other questions:
  • A broadcast network is one in which a transmission from any one attached station is received by all other attached stations over
    10·1 answer
  • In molecular biology the "alphabet" of genes consists of four chemicals (called nucleotides) represented by the letters A C G T.
    12·2 answers
  • ___ consists of a central conductor surrounded by a shield (usually a wire braid).
    9·1 answer
  • En su cuaderno o carpeta de trabajo realice la conversión del sistema de numeración binario a octal según este ejemplo de manera
    13·1 answer
  • In their legacy system. Universal Containers has a monthly accounts receivable report that compiles data from Accounts, Contacts
    6·1 answer
  • Compter History Large Resume Include: the beginnings of the computer and its development during the years The events of computer
    10·1 answer
  • When an instruction is sent to the CPU in a binary pattern, how does the CPU know what instruction the pattern means
    7·1 answer
  • JPG is considered a lossy file format. What does this mean?
    15·2 answers
  • What is wrong with line 3 ?
    11·1 answer
  • In what way can a costume be deleted ?
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!