Write a program that asks the user for the pin

Assignment Help Computer Engineering
Reference no: EM131830940

Problem

When you use an automated teller machine (ATM) with your bank card, you need to use a personal identification number (PIN) to access your account. If a user fails more than three times when entering the PIN, the machine will block the card. Assume that the user's PIN is "1234" and write a program that asks the user for the PIN no more than three times,and does the following:

• If the user enters the right number, print a message saying, "Your PIN is correct", and end the program.

• If the user enters a wrong number, print a message saying, "Your PIN is incorrect" and, if you have asked for the PIN less than three times, ask for it again.

• If the user enters a wrong number three times, print a message saying "Your bank card is blocked" and end the program.

Reference no: EM131830940

Questions Cloud

How much will be in the pool after it doubles : If 10 people are playing the game, and they all chip in their $5 to the pool, how much will be in the pool after it doubles?
What advice might you give about planning the experiment : (a) What questions would you ask her? (b) What advice might you give about planning the ·experiment?
Write a program that calculates a tip : Write a program that calculates a tip according to the diner's satisfaction as Ask for the diners' satisfaction level using these ratings.
Estimate the mean difference produced by the diets : Given the following data on egg production from 12 hens randomly allocated to two different diets, estimate the mean difference produced by the diets and obtain
Write a program that asks the user for the pin : When you use an automated teller machine (ATM) with your bank card. Write a program that asks the user for the PIN no more than three times.
What can you conclude about the relative scarcity of land : Hunting animals specifically for fur was not yet widely practiced. What can you conclude about the relative scarcity of land or animals? Why?
Confidence interval for the difference in mean height : Obtain a 95% confidence interVal for the difference in mean height.
Superscripts in parentheses denote the time order : The superscripts in parentheses denote the time order in which the runs were made. Comment on the data and analyze them.
What type of good was the pilgrims harvest : Why would the communal system reduce something that would have been to the pilgrim's benefit?

Reviews

Write a Review

Computer Engineering Questions & Answers

  Explain the concepts of information systems security as

you are the information security officer for a small pharmacy that has recently been opened in the local shopping mall.

  The difference between a worm and a trojan horse

What do you tell him is the difference between a worm and a Trojan horse. List at least six reasons you can give John for preventing viruses and other malware.

  Should warehouse be included why or why not

The company for whom they are developing the system has just one warehouse location. Should "warehouse" be included? Why or why not?

  Vulnerabilities of routers and web servers

Explain the vulnerabilities of routers and the Web servers and remediation strategies which will make them more secure.

  Addressable virtual address space

2. A machine has a 32-bit byte-addressable virtual address space. The page size is 4 KB. How many pages of virtual address space exist? 5. A computer has 16 pages of virtual address space but only four page frames. Initially, the memory is empty. ..

  Why the lowest possible temperature is absolute zero

Accept inputs from user: a beginning temperature, an ending temperature, and an increment value (all Fahrenheit).

  Questionyou are the ciso for a fortune 500 online

questionyou are the ciso for a fortune 500 online auctioning company that is implementing big data technologies in

  Write down a function named twomax which takes a pointer to

write a function named twomax that takes a pointer to an array of integer numbers array size a pointer to integer which

  Draw the application component diagram for overall system

Itc508 object modeling Assessment - Elaboration phase. In this assessment item, you are required to provide the detailed architecture and design of the system

  How represent these attributes with 3nf relations

how to Represent these attributes using an E-R diagram. Provide meaningful entity names.

  Provide functionality for insertion alongside edition

provide functionality for insertion alongside edition and deletion. Implement field checking for empty fields. -We talked about this on slides and the video contains some information regarding this- Create another table called Admin and include col..

  Draw the memory mar and mbr configurations

Four of the 32 pages of the memory of Problem must be accessible at any time. Four auxiliary 5-bit registers, each containing a page address.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd