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
nikitadnepr [17]
3 years ago
13

Codio Challenge Activity PythonWe are passing in a list of numbers. You need to create 2 new lists in your chart, then put all o

dd numbers in one list put all even numbers in the other list output the odd list first, the even list secondTip: you should use the modulo operator to decide whether the number is odd or even. We provided a function for you to call that does this.Don’t forget to define the 2 new lists before you start adding elements to them.------------------------------------------------------------Requirements:Program Failed for Input: 1,2,3,4,5,6,7,8,9Expected Output: [1, 3, 5, 7, 9][2, 4, 6, 8]------------------------------------------------------------Given Code:# Get our input from the command lineimport sysnumbers = sys.argv[1].split(',')for i in range(0,len(numbers)):numbers[i]= int(numbers[i])def isEven(n) :return ((n % 2) == 0)# Your code goes here
Computers and Technology
1 answer:
lilavasa [31]3 years ago
7 0

Answer:

The python code is given below with lists defined.

Explanation:

import sys

def isEven(n) :

 return ((n % 2) == 0)  //for even items

numbers = sys.argv[1].split(',')

for i in range(0,len(numbers)):

 numbers[i]= int(numbers[i])

even = []

odd = []

for i in numbers:

   if isEven(i):

       even.append(i)  #adds i to even list if it is even

   else:

       odd.append(i)  #adds i to odd list if not even (odd)

print(odd)

print(even)

You might be interested in
When attaching a file or files in outlook 365 you select the attach command and then select the files location
mamaluj [8]

Answer:

When you click the attachment button a window pops up allowing you to select the file/s you want to upload

You can also drag and drop file/s this is an alternative method

Explanation:

Microsoft Outlook is a personal information manager software system from Microsoft.

Though primarily an email client, Outlook also includes such functions as calendaring, task managing, contact managing, note-taking, journal logging, and web browsing. Wikipedia

3 0
2 years ago
Your trying to convince your school that brainly.com is the most effective method to a good tutor and A quick responding site, H
viktelen [127]
I would agree with that Brainly.com is a good place if you need help with homework.
6 0
3 years ago
The _____ approach treats process and data independently and is a sequential approach that requires completing the analysis befo
Solnce55 [7]

Answer:

C. Object Oriented

Explanation:

In Object Oriented approach to development of information systems, processes and data are handled independently and could be tested as separate modules before the actual development begin.

Hope this helps!

4 0
2 years ago
A visual basic application consists of a single file true or false
saw5 [17]
False. When decompiled you can see all the files required for it to run
3 0
3 years ago
Read 2 more answers
The HR department of a company has to send an email notifying an employee of a work performance issue. The manager of this emplo
vivado [14]

The HR department could send the email using the blind copy feature to send it to the manager.

The bcc (blind carbon copy) feature will send a copy of the email to the designated person without the primary recipient knowing that it was sent to them. There is no indication in the email that shows that a message was blind copied.

7 0
3 years ago
Other questions:
  • Please help i really need to turn this in already
    6·1 answer
  • With respect to the general classes of computers, a ________ is the most expensive and most powerful kind of computer, which is
    7·1 answer
  • Which branch of science helps avoid or minimize stress-related injuries at workplace?
    12·2 answers
  • Computers help eliminate that repetitive of manual task. How can this benefit you in in your overall career
    7·2 answers
  • A trust domain is defined as Select one: a. The agreed upon, trusted third party b. A scenario where one user needs to validate
    5·2 answers
  • You have just received a generic-looking email that is addressed as coming from the administrator of your company. The email say
    8·1 answer
  • ! (( i > ( f + 1)) es verdadero o falso segun la logica de programación.
    14·1 answer
  • Which of the following are true about algorithms? (You may select more than one)
    12·1 answer
  • Upload your completed project including the following:
    13·1 answer
  • What would the input, process, outcome and feedback be for a class assignment
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!