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
pochemuha
2 years ago
12

Write a function named reverse_list that takes as a parameter a list and and reverses the order of the elements in that list. It

should not return anything - it should mutate the original list. This can be done trivially using slices, but your function must not use any slicing.
Computers and Technology
1 answer:
WITCHER [35]2 years ago
5 0

Answer:

The function in python is as follows:

def reverse_list(nums):

   half =int(len(nums)/2)

   for i in range(half):

       nums[i], nums[len(nums)-i-1] = nums[len(nums)-i-1],nums[i]

   print(nums)

Explanation:

This defines the function

def reverse_list(nums):

This gets the half the length of the list

   half =int(len(nums)/2)

This iterates through the list

   for i in range(half):

This swaps list items with the opposite item on the other half

       nums[i], nums[len(nums)-i-1] = nums[len(nums)-i-1],nums[i]

This prints the new list

   print(nums)

You might be interested in
Help!! Best answer will get Brainliest!!
Eddi Din [679]

Answer:

answer(s):

-set goals

-select a topic

-write down research questions

Hope this helped and sorry for the bold. <3

Explanation:

6 0
2 years ago
Read 2 more answers
A technician needs to be prepared to launch programs even when utility windows or the Windows desktop cannot load. What is the p
ololo11 [35]

Answer:

Msinfo32.exe, cmd

Explanation:

The msinfo.exe is a tool that gathers information concerning your computer system and displays a comprehensive view of your system components, hardware, and software environment, that can later be use to diagnose computer issues.

Command Prompt is an interpreter application for command line which is available in nearly all Windows operating systems. It is utilized for executing entered commands.

6 0
3 years ago
Characteristics of a cohesive group include all of the following EXCEPT: a. ​support b. a lack of bonding c. mutuality within th
Brilliant_brown [7]

Answer:

Option B i.e., a lack of bonding is the correct answer.

Explanation:

Cohesion is defined as the ability to work in a group, so many time the following situation or problems that are lack of bonding occurs between the mates or the group members because while they achieving their goals there is the understanding problem may occur between them or sometime their ideas should be a mismatch.

4 0
3 years ago
Dev10 is an Active Directory Domain Services (AD DS) domain member that runs Windows 10 Enterprise.
zubka84 [21]
Do I suppose to answer a question please let me know
8 0
3 years ago
Explain what will happen if we continue to use fossil fuels at the rate we are now and what impacts it will have on the planet.
Westkost [7]

Answer:

At the point when non-renewable energy sources are singed, they discharge carbon dioxide and other ozone depleting substances, which thusly trap heat in our air, making them the essential supporters of an Earth-wide temperature boost and environmental change. At the point when we consume oil, coal, and gas, we don't simply meet our vitality needs—we drive the current an unnatural weather change emergency also. Non-renewable energy sources produce huge amounts of carbon dioxide when consumed. Carbon discharges trap heat in the air and lead to environmental change.

7 0
4 years ago
Other questions:
  • The fractional_part function divides the numerator by the denominator, and returns just the fractional part (a number between 0
    8·1 answer
  • What is ASP.NET ?why is it important?
    6·1 answer
  • Which of these statements best describes an application programming interface?
    5·1 answer
  • What is the 7 X 7 when referring to PowerPoint presentations?
    12·2 answers
  • Orifice tubes are A. coded in American models only. B. coded by number for easy identification. C. similarly but not exactly siz
    12·1 answer
  • Over the past few years a very definite need has arisen in the electrical trades for:
    15·1 answer
  • . ____________is/are the JSP ImplicitObject(s).sessionapplicationconfigAll of GivenNone of Given
    9·1 answer
  • A(n) ________ software installation copies all the most commonly used files to your computer's hard drive.
    10·1 answer
  • How do you use switch board in the office​
    6·1 answer
  • * what is an electronic mail ?
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!