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
scoray [572]
2 years ago
6

Def sum_divisors(n): sum =1 # Return the sum of all divisors of n, not including n x=int(n**0.5) for i in range(2,(x//1)+1): if

n%i==0: sum=sum+i if n%i==0 and n/i!=i: sum=sum+(n/i) return sum print(sum_divisors(0)) # 0 print(sum_divisors(3)) # Should sum of 1 # 1 print(sum_divisors(36)) # Should sum of 1+2+3+4+6+9+12+18 # 55 print(sum_divisors(102)) # Should be sum of 2+3+6+17+34+51 # 114
Computers and Technology
1 answer:
Novosadov [1.4K]2 years ago
6 0

Answer:

This is a python program that counts the number of divisors of a given number and calculates the sum of the divisors.

Explanation:

The first line defines a function "sum_divisors" with an argument "n". The square root of the argument is converted to integer and assigned to the variable "x", then a for loop is used to iterate through the range 2 to the calculated nth number of divisors in the argument.The return keyword returns the sum value.

The function is called with several arguments and printed with the print function.

You might be interested in
PLEASE ANSWER ASAP!! Where is the findmore answers page I NEEDDD the bsdge
asambeis [7]

Answer:

hi earlier u told me to answer ur question but i couldn't respond in the comments cos it said something went wrong

Explanation:

do i answer this question seriously or is this answer good?? srry im kinda dûmb T-T

3 0
2 years ago
What specific database stores local user accounts on local computers, and allows users to sign in to and access resources only o
Yuki888 [10]

Answer:

The Security Account Manager

Explanation:

The Security Account Manager (SAM), This is a database file found in Windows Operating Systems.... Windows XP, Windows Vista, Windows 7, 8.1 and 10 that stores users' passwords. It can be used to authenticate local and remote users. It is  an important and vital component of how Windows stores passwords locally on the computer.

5 0
3 years ago
Question 1
Ivanshal [37]

Answer:

Q1. B

Q2. D

Explanation:

3 0
2 years ago
Read 2 more answers
Which of the following cools the air in a household refrigerator?
Ivanshal [37]

The following cools the air in a household refrigerator: Absorption of the heat from the air due to evaporation of the liquid refrigerant . Correct answer:B

The function of the refrigerator is to absorb heat into the refrigeration system. The evaporator is placed in the area to be cooled. The refrigerant vaporizes from the heat it absorbs heat in the evaporator.

4 0
3 years ago
Read 2 more answers
Please help! Why might NASCAR engineers modify racecars to create the type of drag your racecar experienced?
lutik1710 [3]
They modify is bcuz every race car is different and the driver is going to want something different then everyone else. 
4 0
3 years ago
Other questions:
  • You are running an application in Google App Engine that is serving production traffic. You want to deploy a risky but necessary
    9·1 answer
  • How do smart watches affect the business and its position in the global marketplace?
    12·2 answers
  • NOTE: in mathematics, division by zero is undefined. So, in C , division by zero is always an error. Given a int variable named
    10·1 answer
  • Taken together, the physical and data link layers are called the ____________________. Internet layer Hardware layer Internetwor
    15·1 answer
  • To date, what has most propelled the digital revolution?
    10·1 answer
  • 17. Ano ang tawag sa pahina ng Excel?
    12·1 answer
  • Describe how to find and replace a text in a document​
    13·1 answer
  • Explain the characteristics of 1st generation computers​
    15·1 answer
  • PLEASE I NEED HELP WITH THIS, IS FOR TODAY
    10·2 answers
  • How do people and computers approach problems differently
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!