Implement a program that starts by asking the user

Assignment Help Python Programming
Reference no: EM132382463

Question

Implement a program that starts by asking the user to enter a login id (i.e., a string). The program then checks whether the id entered by the user is in the list ['joe', 'sue', 'hani', 'sophie'] of valid users. Depending on the outcome, an appropriate message should be printed. Regardless of the outcome, your function should print 'Done.' before terminating.

Here is an example of a successful login:

>>> Login: joe

You are in!

Done.

And here is one that is not:

>>> Login: john

User unknown.

Done.

Reference no: EM132382463

Questions Cloud

Make a Vodcast presentation : This assessment task requires you to make a 5-minute Vodcast presentation (with audio, written text, and pictures/diagrams) about cancer (breast or prostate)
Write program the computes the minimum number of coins : Write program the computes the minimum number of coins that the cashier can return. To solve this problem use the greedy algorithm explained.
How much profit can you earn on using triangle arbitrage : In New York, you can exchange $1 for €0.7778 or £0.6619. Suppose that, in Berlin, £1 costs €1.151. How much profit can you earn on $17,120 using triangle
Define a class called animal that abstracts animals : Define a class called Animal that abstracts animals and supports three methods. Define Bird as a subclass of Animal and change the behavior.
Implement a program that starts by asking the user : Implement a program that starts by asking the user to enter a login id (i.e., a string). The program then checks whether the id entered by the user.
Write two python expressions that evaluate to the first : Write two Python expressions that evaluate to the first and last, respectively, word in words, in dictionary order. The response paper should be in APA format.
What is the sustainable growth rate for the company : If it does grow at this rate, how much new borrowing will take place in the coming year, assuming a constant debt-equity ratio?
Write python expressions corresponding to the sum : Write Python expressions corresponding to the sum of the first five positive integers and The remainder when 403 is divided by 73.
Economically rational value of the stock today : Assume IBM is expected to pay a total cash dividend of $4.3 next year and dividends are expected to grow indefinitely by 3.3 percent a year.

Reviews

Write a Review

Python Programming Questions & Answers

  Write a python program to list the data types used in this

Write a Python program to load the exact data into a data frame df2016. Write a Python program to list the data types used in this data frame.

  Write program that asks the user to input a set of floating

Write program that asks the user to input a set of floating-point values. When the user enters a value that is not a number, give the user a second chance.

  Describe your analysis in terms of general n

Write a function, largest_34(a), that returns the sum of the 3rd and 4th largest values in the list a. write your analysis in terms of general n.

  Compute the amount of a tip to leave at a restaurant

This purpose of this program is to compute the amount of a tip to leave at a restaurant after a meal. The program asks the user for the amount.

  Write a python program to calculate the average temperature

Write a Python program to calculate the average temperature using a for loop. Finding the frequency distribution of the temperatures.

  Design a python program with a loop that asks the user

Design a python program with a loop that asks the user to enter a series of positive numbers.The user should enter a negative number to signal the end of series

  Creation of a program that will assemble dna chains

The aim of this assignment is the creation of a program that will assemble DNA chains, using the fragments given

  Write a function rmduplic(l), where l is any list

Write a function rmDuplic(L), where L is any list. The function should return a list M that contains the same items as L, except that repetitions (duplicates) have been removed: only the first occurrence of each entry is kept (i.e., order is prese..

  Create a function that takes an argument

Define a function that takes an argument. Call the function. Identify what code is the argument and what code is the parameter.

  The difference between serialisation and deserialisation

Explain the difference between a class variable and an instance variable by referring to how changes made to each will affect other instances.

  Data wrangling - child mortality

ICT702 - Data Wrangling - Child Mortality - Develop creative approaches to solving the wrangling/analysis problems - Write programs that produce correct

  Design a program that asks the user to enter monthly sales

Design a program that asks the user to enter the monthly sales values for six months. The program should store the monthly sales values in a list.

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