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
vesna_86 [32]
3 years ago
5

6.3.6: Adding to a Value codehs help i don't know what to do .

Computers and Technology
1 answer:
QveST [7]3 years ago
4 0

Question:

Write a function that adds together all values from 0 to a given value and returns the final number. For example, if the given value is `4`, you would add 0 + 1 + 2 + 3 + 4

Answer:

In Python:

def add_to_value(n):

   sum = 0

   for i in range(n+1):

       sum = sum + i

   

   return sum

Explanation:

This line defines the function

def add_to_value(n):

This line initializes sum to 0

   sum = 0

The following iteration adds from 0 to n

<em>    for i in range(n+1):</em>

<em>        sum = sum + i</em>

   

This line returns the calculated sum

   return sum

You might be interested in
Please help me. i will mark you brailiest
Stolb23 [73]

Answer:

Simple, really

Explanation:

3Rd one is pretty easy, all you have to do is read closely.

3 0
3 years ago
Which term is used to describe a public-key, cryptography-based mechanism for proving the source (and possibly integrity) of a d
Olegator [25]

The question below has multiple answers

<span>a)      </span>Trusted third party

<span> <span>b)      </span>Symmetric Cryptography <span> <span>c)       </span>Algorithm <span> <span>d)      </span>Digital signature The answer is (D) Digital Signature It uses the private key of a sender and is a mathematical technique that validates the integrity and authenticity through a public key encryption of a digital or a software document. It is normally attached to digital or a software document to verify the sender’s identity and its content. </span></span></span>




5 0
3 years ago
Read 2 more answers
What happen if there is no authentication??
creativ13 [48]

Answer:

anyone could access something and hack others

Explanation:

7 0
3 years ago
Read 2 more answers
.Choose the extention of Scratch Project<br><br><br> .sb2<br><br> jpeg<br><br> .exls
Ratling [72]

Answer:

I know about .sb3, and it similar to .sb2

that might be your answer.

Explanation:

jpeg is for pictures and .exls is Microsoft's excel

extension.

4 0
3 years ago
Read 2 more answers
You want to design a small portable computer system with memory that can be updated, but that does not lose its contents when th
garri49 [273]

Answer:

CMOS

Explanation:

CMOS stands for complementary metal oxide semiconductor.  CMOS is in the design of several types of semiconductors. in most computers there are CMOS that are powered by the PC's batteries to save the memory state of  date, time, and system setup parameters when the PC looses power. In the question above, given the specified parameters for the new system, a CMOS chip will serve perfectly

7 0
3 years ago
Other questions:
  • Theâ ______ is a large worldwide collection of networks that use a common protocol to communicate with one another.
    5·1 answer
  • True or False. A modern programming EXE provides a text editor, a file manager, a compiler, a linker and loader, and tools for d
    9·1 answer
  • What does the word “Gacha” come from??????
    5·2 answers
  • Rita wants to know the size of each image in a folder. Which view will help her find this information quickly?
    13·1 answer
  • A page-ranking algorithm ranks web pages according to
    15·2 answers
  • If i took my SIM card out of my phone and put it in a router then connect the router and my phone with Ethernet cable would the
    12·1 answer
  • Trade Periodicals are usually highly scholarly resources<br> True<br><br> False
    5·1 answer
  • What is range work book​
    8·1 answer
  • During which phase of system development would you acquire any necessary hardware and software?
    11·1 answer
  • Gnome ____ are small programs available on the gnome panel that are designed to give you quick access to useful applications.
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!