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
Dafna11 [192]
3 years ago
8

Grandma Ester normally gives you hugs for your birthday - one for every year old you are. When you turned 15, she squished you w

ith 15 hugs!
This year, she, unfortunately, cannot see you on your birthday, so instead, she wants to send you virtual hugs!
Create a program that prompts the user for how old they are turning and then using a loop, output a virtual hug for every year old they are.
The following prints a single "virtual hug."
print("**HUG**")
Computers and Technology
1 answer:
horsena [70]3 years ago
4 0

Answer:

Written in Python

age = int(input("How old are you? "))

for i in range(1,age+1):

     print("**HUG**")

Explanation:

The first line prompts the user for age

age = int(input("How old are you? "))

The next line is an iteration that starts from 1 till the user input

for i in range(1,age+1):

The last line prints "**HUG**" while the iteration is true

     print("**HUG**")

You might be interested in
Pat is listing the parts of a computer. Which is the best option to use when formatting the list?
Zina [86]
If you mean a web page ten the bet option would be elements, where gives you an unordered list and give you an order list
5 0
3 years ago
What do you understand by the term "Artificial Intelligence "?​
Rzqust [24]

Answer:

Artificial Intelligence (AI) is the branch of computer sciences that emphasizes the development of intelligence machines, thinking and working like humans. For example, speech recognition, problem-solving, learning and planning.

8 0
3 years ago
What does the following code print?double[] myList = {1, 5, 5, 5, 5, 1};double max = myList[0];int indexOfMax = 0;for (int i = 1
Liula [17]

Answer:

This code will print: 4

Explanation:

Following is the step-by-step explanation for the given code:

  • Given is the array of data type double named myList, it has entries, 1, 5, 5, 5,5, 1:

                    double[] myList = {1, 5, 5, 5, 5, 1};

  • Now the first element of the array (1) with index 0 will be stored in the variable max (data type double).

                 double max = myList[0];  

  • A variable indexOfMax having datatype int will be initiated as 0.

                 int indexOfMax = 0;

  • Now for loop will be used to find the maximum number of the array. The variable i will be put as index for each element to compare with first element. If the checked element is greater than or equal to the integer in max, it will be replaced. So at the end the variable max will have value 5 that will be at index i = 4.

                    for (int i = 1; i < myList.length; i++)

                            { if (myList[i] >= max)

                               { max = myList[i];

  • Now the variable i that is the index for max value will be stored in the variable indexOfMax (indexOfMax = 4).

                  indexOfMax = i; }}

  • At end the value stored in variable indexOfMax will be printed, so 4 will be printed as output.

              System.out.println(indexOfMax);

i hope it will help you!

7 0
3 years ago
Effective data communication relies on many components to function collaboratively and reliably. When troubleshooting network pr
enyata [817]

The likely issue cause of the problem in the scenario.

  • Modem: Problem: Dante's home router reports that it's not connected to the internet.

<h3>What is the reason for the above scenario?</h3>

The reason for the modem problem may be due to  some issue that occurs with the connection of the modem device

Therefore, The likely issue cause of the problem in the scenario.

  • Modem: Problem: Dante's home router reports that it's not connected to the internet.  because it is only with the modem that he can connect to the internet and thus need to solve the issue.

Learn more about  communication from

brainly.com/question/26152499

#SPJ1

3 0
2 years ago
Assume that two parallel arrays have been declared and initialized: healthOption an array of type char that contains letter code
eduard

/*

Since we have to check the first two options only as mentioned in last part of question the loop will work 2 times only and will compare the cost of first element and second and assign the healthoption accordingly

*/

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

if(annualCost[i]<annualCost[i+1]

best2 = healthOption[i]

else

best2 = healthOption[i+1]

}

6 0
3 years ago
Other questions:
  • You need to fax a portion of a map from a large hard-cover atlas to a client from an internal fax-modem. To fax the map, the bes
    14·1 answer
  • Ming is building an inexpensive computer to use for her online classes, and needs to purchase Windows. What is the most cost-eff
    8·1 answer
  • What percent<br> of students in<br> the US are<br> considered<br> ESL<br> students?
    5·1 answer
  • Digital manufacturing has impacted our world today! List a reasons why.
    11·1 answer
  • Create pseudocode that could be used as a blueprint for a program that would do the following: An employer wants you to create a
    12·1 answer
  • As part of a team, you are assigned to create a financial report. One of your tasks is to put the pieces together as other team
    5·1 answer
  • Which of the following is the correct financial function that returns the periodic payment for a loan?
    10·1 answer
  • Any one know??please let me know
    15·2 answers
  • It's best to use assertive speech when you<br> I want to show respect. *<br> True<br> False
    8·2 answers
  • Types of Hazards Mitigation Measures
    8·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!