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
solniwko [45]
3 years ago
12

Convert the following code segments as instructed.

Computers and Technology
1 answer:
Kruka [31]3 years ago
3 0

Answer:

Following are the code to this question:

For point a:

value=7#defining a variable value that holds an integer value

if(value>0 and value<10):#use if block with and operator to check the value

print("did it")#print message

For point b:

my_str="not_password"#defining a variable my_str that holds string value

if (len(my_str) > 0):#defining if block that checks string variable length is greater than 0  

   if (my_str!= "password"):#defining if block to check my_str is not equal to another given value

       print("did it")#print message

For point c:

my_str="not_password"#defining a variable my_str that holds string value

if (len(my_str) > 0):#defining if block that checks string variable length is greater than 0

   print("did it")#print message

elif (my_str!="password"):#use elif block to check my_str is not equal to another given value

   print("did it")#print message

Output:

did it

did it

did it

Explanation:

Please find the complete and the correct question in the attached file.

In point a, the "value" variable is defined, that holds an integer value , and it uses if block with "and" operator to check the value is greater than 0 and less than 10, and at the last, it will print the message "did it".

In point b, the "my_str" variable is declared, that holds a string value , and use the multiple if block in this, it checks the length is greater than 0, and in another, if it checks its "my_str" value is not equal to another given value, and it prints the message "did it".

In point c, the "my_str" variable is declared, that holds a string value , and use the if block, it checks the length is greater than 0, it will print the message "did it".  In the elif block, it checks "my_str" value is not equal to another given value, and it prints the message "did it".

You might be interested in
How do u get rid of this (the grey box)
slamgirl [31]

Answer:

can't helpnyounddjdjzjzjsjejs jvm d

8 0
4 years ago
Read 2 more answers
a user reports that his dot matrix printer is printing dark and clear on the left of the paper but that the print is very light
yarga [219]

Answer:

Correctly position the platen of the printer to hold the paper in place.

Explanation:

Since the dot matrix printer is printing dark and clear on the left of the paper but very light on the right side of the paper, it is possible that the paper is not being held properly. So adjusting the platen will hold the paper properly and hence uniform prints on the paper.

Note: Dot matrix printers are printers that print closely related dots to form require texts (shapes) by striking some pins against an ink ribbon.

Some of the parts of these printers are; power supply, carriage assembly, Paper sensor, ribbon, platen and pins.

4 0
3 years ago
What was one important academic skill the blogger learned?
denis23 [38]

An academic skill that the blogger learned, was to review the graded tests and quizzes to see which concepts he missed out on so that in the future he would be well prepared for it. Reviewing and comparing the tests and quizzes would give him an idea on which topics he needs to study.

Other than the academic skill, the blogger also learned that a person should never give up and he keeps on learning throughout his entire life, and that all of the improvements that the blogger made did not come all at once.

4 0
4 years ago
What two Python data structures are already thread-safe, because they provide automatic support for synchronizing multiple reade
murzikaleks [220]

The  two Python data structures that are already thread-safe are list and tuples.

<h3>What are the data structures in Python?</h3>

Python is known to give room for its users to make  their own Data Structures.

It helps one to be able to  have total hold or control over their work or output functionality. Some key Data Structures are Stack, Queue, and others.

Learn more about Python from

brainly.com/question/26497128

#SJ1

6 0
3 years ago
What four things does steering control involve?
Dafna1 [17]

Answer:

putting your hands one the wheel, putting the car in gear, putting your foot on the brakes when you need to, and watch for cars when you're driving. hope it helps

Explanation:

7 0
3 years ago
Other questions:
  • Write the percentage 5 1/4 as a decimal​
    8·1 answer
  • To what are multiple servers arranged in racks related
    14·2 answers
  • Communications technology and the Internet can be used to reduce the time and costs involved in disseminating financial statemen
    14·1 answer
  • Finish the statement below to correctly describe the Defense Enrollment Eligibility Reporting System (DEERS). DEERS is a central
    6·1 answer
  • 0x400C (in hexadecimal)?
    8·1 answer
  • What are the ethical implications of online social media after someone has died
    8·2 answers
  • How do graphic designers showcase their work?
    14·2 answers
  • Describe three perimeter intrusion detection systems and give an example of one that you have seen deployed either at work or an
    8·1 answer
  • To switch from one open document to another, press _____.
    6·1 answer
  • 8. Which of the following is an output device
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!