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
marishachu [46]
4 years ago
11

Assign testResult with 1 if either geneticMarkerA is 1 or geneticMarkerB is 1. If geneticMarkerA and geneticMarkerB are both 1,

then assign testResult with 0. If geneticMarkerA and geneticMarkerB are both 0, then assign testResult with 0. Ex: If geneticMarkerA is 1 and geneticMarkerB is 0, then testResult is assigned with 1. If geneticMarkerA is 1 and geneticMarkerB is 1, then testResult is assigned with 0.
Computers and Technology
1 answer:
OverLord2011 [107]4 years ago
4 0

Answer:

Following python statement will give the assignment to testResult as specified:

if((geneticMarkerA == 1) or (geneticMarkerB ==1)):

   testResult = 1

if((geneticMarkerA ==1) and (geneticMarkerB == 1)):

   testResult = 0

if((geneticMarkerA == 0) and (geneticMarkerB == 0)):

   testResult = 0

Explanation:

In above statements or and and operator are used to check the conditions of set of values present in variable geneticMarkerA and geneticMarkerB.

Based on if the condition evaluate to true or false respective values to testResult varaible is assigned.

Following is sample run for above statements:

geneticMarkerA = 1

geneticMarkerB = 0

if((geneticMarkerA == 1) or (geneticMarkerB ==1)):

   testResult = 1

if((geneticMarkerA ==1) and (geneticMarkerB == 1)):

   testResult = 0

if((geneticMarkerA == 0) and (geneticMarkerB == 0)):

   testResult = 0

print(testResult)

Output

1

You might be interested in
Biometric devices are often associated with computer and data security. True False
Leya [2.2K]

Answer:

True

Explanation:

5 0
3 years ago
This is my new horrible subject lol
AysviL [449]
I’m 98% sure that it is B because customer service would be provided to people who buy from the company and need help
5 0
4 years ago
Shelly and Donna are discussing System Restore. Shelly says when the System Restore program creates and saves a copy of your com
pav-90 [236]
The answer is D, because it's called a back-up.
4 0
3 years ago
Most common level of education for a programmer or software developer
shusha [124]

c/c+ also java would be one

8 0
3 years ago
Why was the 80s bad for Disney i know one example but ill tell you after you answer
Bond [772]

Answer:

The dark stories behind it? i dont  know lol

5 0
3 years ago
Other questions:
  • 1- Design a brute-force algorithm for solving the problem below (provide pseudocode): You have a large container with storage si
    10·1 answer
  • What type of organizational structure would you want to use for this company (by function, by process, by product, and so on)? E
    11·1 answer
  • When you write a C# program that stores a value in a variable, you are using temporary storage; the value you store is lost when
    12·1 answer
  • ERP packages are always quite simple.<br><br> True<br><br> False
    5·1 answer
  • Now let's create a memo. The memo should include all parts of a memo, and these parts should appear in the correct order. In you
    9·1 answer
  • My friend has a battery of 9000mah and loses 10 every day how many days well it take to go to zero
    13·1 answer
  • Wearables, video playback and tracking devices can help athletes because
    15·1 answer
  • Use the drop-down menus to answer the questions.
    6·1 answer
  • PLS I NEED HELP Question 6<br> 1 pts<br> What is NOT a built-in function in python?
    5·1 answer
  • What four things does steering control involve?
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!