You have a unique id number, which is represented by the variable id, containing a string of numbers. write a program that continuously takes strings to standard input. if the string is not your id number, print "this is not your id number." if it is, print "this is your id number: " followed by the number, and terminate the loop.

Answers

Answer 1

idNumber = "123456"
idNo = input("Enter the unique ID number: ")
while idNumber != idNo:
print("This is not your ID number.")
idNo = input("Enter the unique ID number: ")
print("This is your ID number: ", idNo)

Output:

sh-4.3$ python3 main.py                                                                                                                                                                                                                                                

Enter the unique ID number: 2345                                                                                                                                                                                                                                       

This is not your ID number.                                                                                                                                                                                                                                            

Enter the unique ID number: 4563                                                                                                                                                                                                                                       

This is not your ID number.                                                                                                                                                                                                                                            

Enter the unique ID number: 12345                                                                                                                                                                                                                                      

This is not your ID number.                                                                                                                                                                                                                                            

Enter the unique ID number: 123456                                                                                                                                                                                                                                     

This is your ID number:  123456

Answer 2

To print a unique ID number which is represented by a variable and it contains string of numbers . For this, first declare the unique ID then create a variable that take inputs from the keyboard. After this, create a loop that will match with your unique number (ID). Lastly, display a message if ID is matched then print ‘This is your ID number’ and if it is not matched then print ‘This is not your ID number’.

Further Explanation:

Code:

The complete code in python language for the given problem is shown below:

# Your unique ID number

id = "12345"

# Enter the ID  number

number = input ("Enter an ID: ")

# Loop to match the ID number with input

while id !=number:

# Print the message

print ("This is not your ID number")

number = input ("Enter an ID: ")

print("This is your ID number:", number)

Output:

Run the commands in python, the output will be looking as below:

Enter the unique ID number: 24345

This is not your ID number

Enter the unique ID number: 1345                                                    

This is not your ID number

Enter the unique ID number: 12345  

This is your ID number

Enter the unique ID number: 35645                                                

This is not your ID number

Learn more:

1. A company that allows you to license software monthly to use online is an example of ? brainly.com/question/10410011  

2. Prediction accuracy of a neural network depends on _______________ and ______________. brainly.com/question/10599832  

Answer details:

Grade: College Engineering

Subject: Computer Science and Engineering

Chapter: Python Programming

Keyword:

Python, input, output, programming, statements, if-else, loops, print, scan. while, body, main body, char, int, variables, unique, ID number, match


Related Questions

Describe a scenario for which a find unmatched query could be used.

Answers

unmatched query can be used when you use one table to store data about an item, and another table to store data about items movement such as sales that involve that thing. To determine which items are idle these stored information is not enough because the item movements table includes data only about items that have been sold. You must compare the two tables to determine which items are idle. In such situations this query is used

What element is used to configure a new paragraph?

Answers

You skip a line down and then u indent and start a new paragraph(please don't report if wrong)

why is it important that the ribbon tabs collapse? a) it lets you free up more screen real estate and see more of the work area. b) it prevents you from accidentally hiding the entire window. c) it highlights mistakes in your typing. d) it allows you to easily view previous versions of your work alongside the current version

Answers

a) it lets you free up more screen real estate and see more of the work area

Answer:

a) it lets you free up more screen real estate and see more of the work area.

Explanation:

Sometimes the ribbon tabs are useful to see the tools and previous work that you have done, the problem is that take some space from the work area from the screen so if you close them you can actually free up space and get to see more of the work area and this can help you see more of the document and focus on the work.

Bullets in a text box will do which of the following? (this is in relation to powerpoint)

A) Ensure you fill up the slide with text

B) help you present your data with has concise statements.

C) Help you properly size your text

D) Ensure you leave space for drawings

Answers

Bullets in a text box will do which of the following? (this is in relation to powerpoint)


B) help you present your data with has concise statements.

What project started the development of inter-network connections using tcp/ip that has evolved in to the internet today

Answers

The ARPANET project started the development of inter-network connections using TCP/IP that has evolved in to the internet today

Why would you activate more than one nic on a pc?

Answers

For redundancy in case of failure or for connecting them to different subnets. 

The activation   of multiple NICs can help boast throughput to and from the application servers and also gives failover.

What is application server?

An application server is known to be a tool that help give access to business logic that are said to be use in terms of client application programs.

Therefore, The activation  of multiple NICs can help boast throughput to and from the application servers and also gives failover.

Learn more about  application servers  from

https://brainly.com/question/14922758

#SPJ2

Flashcar a network administrator is considering placing a firewall on an internal file server in the network. what is the purpose of the firewall, and is it important for the firewall to be stateful?

Answers

well in order for it to work it need a fast working server which will need a background, this may be different , but its like an upgrade

Final answer:

A firewall on an internal file server protects against unauthorized access and cyber threats by monitoring network traffic. A stateful firewall enhances security by tracking active connections and making decisions based on traffic context.

Explanation:

A firewall is a network security device that monitors and filters incoming and outgoing network traffic based on an organization's previously established security policies. At its most basic, a firewall serves as a barrier between a private internal network and the public Internet. The purpose of placing a firewall on an internal file server is to protect the server from unauthorized access, cyber threats, and to control data flow to and from the server.

A stateful firewall is designed to keep track of the state of active connections and can make decisions based on the context of traffic, such as the characteristics of the connection (e.g., connection start, connection end, connections originating from a file server or aiming to reach it). This is important because it allows the firewall to distinguish between legitimate network traffic and potentially harmful activity, thereby providing a higher level of security. Using a stateful firewall helps to ensure that established connections are secure and that new connections are scrutinized more rigorously.

Write c++ code that prints: usernum ... 2 1 blastoff! your code should contain a for loop. print a newline after each number and after blastoff!.ex: usernum = 3 outputs: 3 2 1 blastoff!

Answers

#include <iostream>
int main() { int usernum = 3;
for(int i = usernum; i >= 1; i--) { std::cout << i << "\n"; } std::cout << "blastoff!\n";
return 0;}
Works fine my dude:
./randombrainly 321blastoff!

John is selling his pizza for $6 per slice in an area of high demand. However, customers are not buying his pizza.
Using what you learned about the principles of equilibrium, write three to four sentences about how John could solve his problem.

Answers

John's prices are too high. This is causing excess supply: John's workers can make many pizzas, but at these high prices, consumers are only demanding a small amount. If the price per slice decreased, consumers would demand more of John's pizza. This means that business would move toward a point of equilibrium, where supply matches demand at the appropriate price.

Assume you have written a method with the header num mymethod(string name, string code). the method's type is

Answers

I need answer choices

While in slide show mode, a click and a drag is no different than a click

True or false

Answers

It is true that while in slide show mode, a click and a drag is no different than a click.
Just try it for yourself - there is no dragging when you are in slide show mode. Anything you do, press a button, click and try do drag, will be considered to be a simple click. 

Which field data type would you use if you'd like to store videos in that field a text b memo c Boolean D binary object E null

Answers

The answer is D. Binary Object :)

Binary object data type one would use if you'd like to store videos in that field. The correct option is D.

What is data type?

In programming, a data type is a classification that specifies what type of value a variable has and what mathematical, relational, or logical operations can be performed on it without causing an error.

If you want to store videos in a binary object data type field in a database, you would use a BLOB (Binary Large Object) data type.

BLOB is a data type that can store binary data as a single entity in a database table, such as images, audio, and video files.

Large amounts of unstructured data, such as media files, are typically stored in BLOBs because they are too large to be stored in standard character-based data types.

Thus, the correct option is D.

For more details regarding data type, visit:

https://brainly.com/question/14581918

#SPJ7

Tasha purchased a new tablet. She has several questions about how to connect to the internet, download apps, install software, and sync her other devices.

Which type of resource would be best, and why?

A) Bulletin board; shows other user's comments
B) FAQ; answers questions about common issues
C) Manual; provides all information related to the device
D) Tutorial; explains each stage of the process

Answers

Answer:

c

Explanation:

Its best to be related directly to the device

The type of resource  that would be best is Manual; provides all information related to the device.

What is device operation?

Operating device is a term that connote the act of handling an electronic device, such as electronic tablet.

Note that The type of resource  that would be best is Manual; provides all information related to the deviceas it will help her to know the basic features.

Learn more about device from

https://brainly.com/question/917245

#SPJ2

Pointswhat is the shell command (and option) to turn off a linux computer immediately?

Answers

Depending on the OS:

init 0

shutdown -p now  # may be mapped to systemctl

systemctl poweroff

Answer:

Hello, how are you, you may not answer since this question was posted in 2017...

Explanation:

what does the narrator of the film epic 2015 say it will be at it'
s worst

Answers

Answer

A collection of trivial information that may not be true

Explanation

Epic in films is a work of art that resembles an epic situation; magical mix of talents that has the ability to make a film build sense inside the audience. Epic requires internal, immediate and global components which will comprise the plot line. For example in the film, Bride on the River Kwai, led character are involved in an epic battle


In which cipher method are values rearranged within a block to create the ciphertext?
a. vernam
b. monoalphabetic
c. substitution
d. permutation?

Answers

i not sure but i think the answer is c. substitution

What controls a computer's basic operations?

Answers

Basic Computer Operations. Input: Information and programs are entered into the computer through Input devices such as the keyboard, disks, or through other computers via network connections or modems connected to the Internet.

What are Computer's operations?

An operation in computing is a process used to complete a certain task. Input, processing, output, storage, and control are the five types of computer processes.

The five major components of a computer system carry out computer functions. Each of the five primary types of operations can be directly matched with one of the units.

The control flow is shown by the blue dotted lines and is represented by the black arrows. User commands are delivered to the computer.

Therefore, Basic Computer Operations. Input: Information and programs are entered into the computer through Input devices such as the keyboard, disks, or through other computers via network connections or modems connected to the Internet.

To learn more about operations, refer to the link:

https://brainly.com/question/28335468

#SPJ5

The CPU and operating system control a computer's basic operations. The CPU processes instructions, while the operating system allocates hardware resources and manages software interactions.

A computer's basic operations are controlled primarily by the Central Processing Unit (CPU) and the Operating System (OS). The CPU is often referred to as the 'brain' of the computer, as it executes instructions and processes data at incredibly high speeds.

The operating system, meanwhile, manages and allocates hardware resources, ensuring that various software applications can function correctly. It controls interactions with hardware such as reading and writing files to a hard drive, displaying graphics on the monitor, and managing memory usage. Without an operating system, each individual program would struggle to function efficiently and securely.

Summary: The CPU is obsessed with processing instructions while the OS acts as a mediator, managing resources and orchestrating the activities of other programs to ensure seamless operation.

Which of these is NOT a good presentation technique?

A. Speaking loudly enough that everyone in the audience can hear you
B. pronouncing words very clearly and speaking at a normal pace
C. using dramatic gestures to emphasize important points
D. making eye contact with the audience

Answers

The answer would be D.
D making eye contact can be distracting as well as just not looking very polished hope it helped!

a few questions related to power point.

Answers

Here is what I gathered from these questions:

Question 2: More than one text box
Question 3: All of these

Hope this helped ^-^

What is contingency planning and how is it different from routine management planning? 


Answers

A contingency plan is created by entity in order to anticipate events that would possibly threaten assets and security of the organization. This would allow for reacting and recovering to restore normal business operations.

Which of the following question u should ask your boss regarding individual performance evaluations

Answers

I would go with "B" but don't quote me on that.
The answer to this question is  What measurements will be used to evaluate me?
When you ask this question, you convey two things to your boss:
- First, is that you're interested in finding out what standards that your boss consider as good
- Second, is that you're willing to put in the works in order to meet that standard

and this will end up causing your boss to see that you're a competent worker.

In _____, a person or a device intentionally or unintentionally interferes with your wireless network transmissions. select one:

a. rf jamming

b. war driving

c. eavesdropping

d. telemetry

e. installing rogue access devices

Answers

the answer is rf jamming

A database, a database management system, and the application programs that use the data make up a database environment.
a. True
b. False

Answers

Well, it's true in a way if you are looking at it from use of data which consist of software, hardware, and people. Database environment is basically the enclosure(encapsulation) of one or more database deployed in same or different servers.

A program ____ is an abstraction of a computer memory cell or collection of cells.

Answers

A variable. Hope I could help you

"​the three legs of a project triangle are _____, scope, and time."

Answers

The project cost is the third leg of the triangle. This is one of the most important parts, simply because this can determine what parts of the project can or cannot be undertaken. Without the proper funding for the project, little can likely be done.

In the osi (open system interconnection) model, data proceeds up through the layers on the receiving computer. true false

Answers

True. The OSI model presents a standard data flow architecture, with protocols specified in such a way that the receiving layer at the destination computer receives exactly the same object as sent by the matching layer at the source computer.

Open a command prompt on pc-a and pc-b and type ipconfig /all. what are the ethernet adapter physical addresses?

Answers

The Physical addresses are known as the MAC address and show as
3C-XX-XX-XX-XX-XX  OR C--XX-XX-XX-XX-XX

A. experiment by purposely misconfiguring the gateway address on pc-a to 10.0.0.1. what happens when you try and ping from pc-b to pc-a? do you receive a reply?

Answers

Yes you will mate, hope this helps!

Calls to the tostring( ) method emphasize the use of ____.

Answers

Polymorphic message
   
Methods in different classes with a similar function are given the same name. - Makes classes easier to use because programmers need to remember fewer method names. - Employed as much as possible. - Polymorphic message ex. is the toString method.

What is the common voltage for a cordless drill battery cell? A. 1.5 VDC B. 2.0 VDC C. 1.0 VDC D. 1.2 VDC

Answers

the ones here in texas are b it just deponds where you are
Final answer:

The common voltage for an individual cordless drill battery cell is closest to 1.2 VDC, typical of NiCd and NiMH cells, which are commonly used in the battery packs of cordless drills.

Explanation:

The common voltage for a cordless drill battery cell is not explicitly mentioned in the provided reference information. However, we can deduce that typical voltages for cells that are used in various electronic devices and tools vary. For cordless drills, the batteries are often made up of multiple cells to reach a higher voltage needed for their operation, typically ranging from 12V to 18V or more, depending on the design and purpose of the drill. Each cell in a battery pack might have a nominal voltage of around 1.2V to 3.6V, depending on the technology (NiCd, NiMH, or Lithium-ion) used in the battery pack. Options A (1.5 VDC), B (2.0 VDC), C (1.0 VDC), and D (1.2 VDC) represent common voltages for individual cells rather than the entire battery pack of a cordless drill. The closest common voltage for rechargeable cells used in battery packs, including those for cordless drills, is 1.2 VDC (Option D), typical of NiCd and NiMH cells.

Other Questions
Are number 2,3,5,7 and 8 correct? "the house of representatives shall be composed of members chosen every second year by the people of the several states..." which of the seven principles of the constitution does this quote exemplify? * What are the next three terms of the geometric sequence 32, -16, 8, ? a.2, 1, 1/2c.-8, 16, -32b.4, 2, 1d.-4, 2, -1 a ______ in the house can limit the amount of time to debate a billA)speaker B)commitee of the whole C)rules commiteeD)discharge petition To prevent your children from swimming in their pool when you are not home, you don't allow them to stay home alone when you are not there. if you send them to the neighbor's house instead, you are using ____________. How did the crusades help lead to the creation of modern europe's nation states? Which of the following is determined by an individuals placement in the caste system? A) Moksha B) Dharma C) Karma D) Atman A 1.20 g sample of an unknown has a volume of 1.73 cm what is the density of the unknown United States citizens can practice any religion they want under which amendment to the Constitution? Which planets diameter is approximately 1/200 of the sun's diameter?explain 40 points ;Call Of The Wild please answer A __________ is a polysaccharide layer that lies outside the cell wall and is not easily removed. Nails cost $.13 per pound and screws cost $.21 per pound. Michelle bought 1.5 pounds of nails and 3.4 pounds of screws. How much did she pay for the nails and screws? A scientist studying bacteria begins with 20 cells. The bacteria population doubles every hour. Complete the table below to determine after how many hours there will be more than 500 bacteria cells. Time (hours) Number of bacteria cells 0 20 1 40 2 80 3 4 5 6 Write an exponential function to model this situation. Predict the bacteria population after 11 hours. Which idea listed above most likely influenced the struggle to end slavery in the United States in the 19th century?Sentence 1Sentence 2Sentence 3Sentence 4 Sweet t has 2 orange picks for every green pick . If 6 picks are green, how many are orange In a campaign, the volunteers who are in charge of going door-to-door in order to explain information about the candidate and issues are working as __________. if the smaller of two consecutive intergers is subtracted from two times the larger then the result is 17 . find the intergers In which of the following two ways did the Roman empire differ from the Roman republic?Select all that apply.. In which of the following two ways did the Roman empire differ from the Roman republic?Select all that apply.provided for direct election of emperors by citizensinstituted a census for taxation purposeseliminated the senatecentralized absolute power in one rulerpulled back from expansion and reduced trade What is the probability that two heterozygous parents would have an offspring that produces round seeds? Steam Workshop Downloader