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
photoshop1234 [79]
3 years ago
14

9.4 Code Practice: Your task is to determine whether each item in the array above is divisible

Computers and Technology
1 answer:
wariber [46]3 years ago
7 0

Answer:

Explanation:

The following Python code is a function that takes in an array as a parameter, it then loops through the array determining if the element is divisible by 3. If it is it leaves it alone, otherwise it changes it to a 0. Then ouputs the array. A test case is shown in the attached image below using a sample array.

def divisible_by_three(array):

   for x in array:

       if x % 3 == 0:

           pass

       else:

           array[array.index(x)] = 0

   return array

You might be interested in
If you ping a device, you are using the______protocol
meriva
Joystick..................:-)
6 0
3 years ago
1.Which of the serves as the basis for determining whether an object has moved or not?
Harrizon [31]

Answer:

1. b

2. c

3. b

4. d

5. a

(hope this helped)

4 0
2 years ago
Quick!!!!!
Vlad [161]

Answer:

B. the current affairs page

Explanation:

it's a simple question

8 0
3 years ago
Read 2 more answers
A student is helping a friend with a home computer that can no longer access the Internet. Upon investigation, the student disco
Alexxandr [17]

Answer:

Due to unreachable DHCP server

Explanation:

As we know that Dynamic Host Configuration Protocol, in short  DHCP is the network protocol which is used to central and automatic management of IP address with in the network.

So due to unreachable DHCP server a student could not able to connect with the internet.When the network connection break it means that DHCP server is offline.

So the answer is Due to unreachable DHCP server .

8 0
3 years ago
Extend the class linkedListType by adding the following operations: Write a function that returns the info of the kth element of
WINSTONCH [101]

Answer:

Explanation:

The following code is written in Java. Both functions traverse the linkedlist, until it reaches the desired index and either returns that value or deletes it. If no value is found the function terminates.

public int GetNth(int index)

       {

       Node current = head;

       int count = 0;

       while (current != null)

       {

       if (count == index)

       return current.data;

       count++;

       current = current.next;

       }

       assert (false);

       return 0;

       }

public int removeNth(int index)

       {

       Node current = head;

       int count = 0;

       while (current != null)

       {

       if (count == index)

       return current.remove;

       count++;

       current = current.next;

       }

       assert (false);

       return 0;

       }

6 0
3 years ago
Other questions:
  • Will upvote all answers
    7·1 answer
  • Who is responsible for customer service?
    14·1 answer
  • What is the windows server 2012 r2 feature that enables you to maintain previous versions of files on a server, so that if users
    10·1 answer
  • • The length of time between water level measurements/ control adjustments is DT. • If the water level drops to the bottom of th
    13·1 answer
  • In an income statement subtracting the cost of goods sold from the net sales provides the?
    11·1 answer
  • This project involves writing a program that encodes and decodes messages. The program should prompt the user to select whether
    15·1 answer
  • What is the full form of 'Rom<br>​
    7·2 answers
  • 9.
    8·1 answer
  • Think of some local businesses that have websites. Look online and identify two different websites for businesses or services in
    11·1 answer
  • What does syntax error mean :-;<br>explain briefly.<br><br>thankyou!
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!