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
nevsk [136]
3 years ago
11

A loop that will output every other name in the names list.

Computers and Technology
1 answer:
Nuetrik [128]3 years ago
4 0

Answer:

names = ['Peter', 'Bruce', 'Steve', 'Tony', 'Natasha', 'Clint', 'Wanda', 'Hope', 'Danny', 'Carol']

numbers = [100, 50, 10, 1, 2, 7, 11, 17, 53, -8, -4, -9, -72, -64, -80]

for index, element in enumerate(names):

if index % 2 == 0:

 print(element)

for num in numbers:

 if num >= 0:

   print(num, end = " ")

count = 0

for i in numbers:

 count += i

avg = count/len(numbers)

print("sum = ", count)

print("average = ", avg)

for num in numbers:

 if num % 2 != 0:

   print(num, end = " ")

Explanation:

I'm stuck on the last two.. I have to do those too for an assignment.

You might be interested in
Scenario: 1. Victim opens the attacker's web site. 2. Attacker sets up a web site which contains interesting and attractive cont
Ann [662]

Answer :

These sort of attacks are known are Injected IFrame Attacks. The Injected IFrame Attacks are a common Cross Site Scripting or XCC attack that contains multiple or single iFrame tags implemented within a page which is not visible to user. User unintentionally enters his information which is posted to hacker’s server and information’s gets hacked.

5 0
3 years ago
________ is a crime that uses mock (fake) sites to trick people into sharing information.
Elan Coil [88]
<span>Phishing is a crime that uses mock (fake) sites to trick people into sharing information.</span>
5 0
3 years ago
To create a window, which of thefollowing classes has to be extended?ContainerJFrameJButtonJTextField
irga5000 [103]

Answer:

J frame class has to be extended for the creation of a window

Explanation:

J frame needs to be extended to create a window, this is because this class in windows has a title, support buttons components, a border or we can say it has decorations for windows.  

The rest of the classes like J button and J text fields lie within the J frame and the Container class is a super class and provides only outlines to J Frame class.

3 0
3 years ago
In a four-stroke engine, the time period when both valves are slightly open is called valve
Thepotemich [5.8K]
Answer to my knowledge is d. overlap
3 0
3 years ago
Write a program that asks the user to type 5 integers
AnnZ [28]

import Java.util*

public class Average{
public static void main(String [] args){

int sum = 0;
int numbers = 0;

for(int i = 0; i < 5; i++){
Scanner sc = new Scanner(System.in);
System.out.println(“Please enter your integers: “);
numbers = sc.nextInt();

sum += numbers;
}
System.out.println(“The average is: “ + sum/5)”
}
}
5 0
3 years ago
Other questions:
  • If you want to copy text formatting from one area of your document to another area, _____. a. select the formatting you would li
    5·1 answer
  • Which information is necessary to determine an object's speed?
    13·1 answer
  • How many water bottles must be collected to win?
    8·2 answers
  • Why is the cost of a software project not directly related to the cost of development?
    13·1 answer
  • Who created apple and in what year was it created
    9·2 answers
  • When referring to hard drives, access time is measured in
    11·1 answer
  • Your computer uses 4 bits to represent decimal numbers (0, 1, 2, 3 and so on) in binary. What is the SMALLEST number for which a
    8·1 answer
  • Compare the two items in a summary of qualifications taken from a resumé. Which is better?
    9·1 answer
  • A list is sorted in ascending order if it is empty or each item except the last one is less than or equal to its successor.
    14·1 answer
  • ANYONE WANNA FRIEND ME ON DISCORD ゴRose joestarゴ#2088
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!