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
Elis [28]
3 years ago
6

Write a new recursive function countup that expects a negative argument and counts "up" from that number. Output from running th

e function should look something like this:__________.
>>> countup(-3)
-3
-2
-1
Blastoff!
Computers and Technology
1 answer:
serious [3.7K]3 years ago
4 0

Answer:

function:

def countup(n):

   if(n<0):

       print(n)

       countup(n+1)

   else:

        print("Blastoff!")

Output:

  • If the user pass (-3) for the value of n, then it will prints the above output.

Explanation:

  • The above code is in python language, which has a function of "countup" which will print the all decrement value of n until the value is less than 0.
  • The above function is a recursive function that will give the output if the user gives it a negative value, otherwise, it will print "Blastoff!" for any positive or zero value.

You might be interested in
Hellpppppppppppppppp
jonny [76]

Answer:

i can't see your problem

6 0
3 years ago
Read 2 more answers
Identify three errors in this HTML code snippet:
Kazeer [188]

I have annotated the errors in the picture.

<em />

<em>Hope this helps :)</em>

5 0
2 years ago
Read 2 more answers
Cloud Kicks is undergoing a GDPR-focused implementation to ensure access to personal information data is limited to only users w
bija089 [108]

Answer:

Option A.

Explanation:

It is experiencing a GDPR-focused execution to assure only users who require full rights to a corporation's account have access to sensitive information and data. It has a design of their personal account.

So, the Consultant allows particular Account privileges to the sustainable and Sales Procedure teams through which they create Renewals and Sales Operation Account team membership roles and has sales team members allocated to the suitable customers.

5 0
3 years ago
Write a program that prompts the user to enter the number of integer numbers you need to enter, then ask user to enter these int
nadya68 [22]

Answer:

import java.util.Scanner;

public class Main

{

public static void main(String[] args) {

 Scanner ob = new Scanner(System.in);

 System.out.println("How many numbers? ");

 int n = ob.nextInt();

       int[] arr = new int[n];  

 for (int i=0; i<n; i++) {

     System.out.print("Enter the number: ");

     arr[i] = ob.nextInt();

 }

    System.out.println(indexOfLargestElement(arr));

}

public static int indexOfLargestElement(int[] arr) {

    int max = arr[0];

    int maxIndex = 0;

    for (int i=0; i<arr.length; i++) {

        if (arr[i] >= max) {

            max = arr[i];

            maxIndex = i;

        }

    }

    return maxIndex;

}

}

Explanation:

Create a method called indexOfLargestElement that takes one parameter, an array

Initialize the max and maxIndex

Create a for loop iterates throgh the array

Check each element and find the maximum and its index

Return the index

Inside the main:

Ask the user to enter how many numbers they want to put in array

Get the numbers using a for loop and put them inside the array

Call the indexOfLargestElement method to find the index of the largest element in the array

8 0
3 years ago
A cookie is stored on your device's memory or disk in what file format? 1.)video file
Natalka [10]

Answer:

text file format

4 this is the answer

4 0
2 years ago
Other questions:
  • Plz answer and dont put a random thing for the points
    11·1 answer
  • Which three phrases describe a wireframe
    12·1 answer
  • Is printer an input device​
    5·1 answer
  • There are several factors that can substantially affect the consumer search process. Match the factor with an example of how the
    5·1 answer
  • give your opinion on if you would trust your accounts with an online bank. Explain why or why not. MANY people do not. MANY peop
    14·2 answers
  • Suppose one hundred stores participated in the
    14·1 answer
  • What is the range of possible sizes for side<br> x?<br> 4.0<br> 2.7
    8·1 answer
  • The repeated use of electronic communications, such as chat rooms and email, to seek out, harass, or frighten someone is called
    12·1 answer
  • Charlie makes pizza at a restaurant. The customers always compliment how great the pizza tastes. But Charlie takes a long time t
    7·2 answers
  • I'm in Paris and want to take a picture of my mom in front of the Eifel Tower. I want both her and the tower to be in sharp focu
    14·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!