Asks the user for the number of males and number of females

Assignment Help Python Programming
Reference no: EM132113584

In Python

Write a program that asks the user for the number of males and the number of females registered in a class using two separate inputs ("Enter number of males:", "Enter number of females:").

The program should display the percentage of males and females (round to the nearest whole number) in the following format:

Percent males: 35%

Percent females: 65%

Use string formatting.

Reference no: EM132113584

Questions Cloud

A program that creates a number grid based on user input : Write a program that creates a number grid based on user input. Prompt the user for the number of rows and columns in the number grid.
Create a minimax function that evaluates the best possible : Create a minimax function that evaluates the best possible move for depth of 5, where AI moves want to be maximized and USER moves want to be mimized.
Find the z-score corresponding to the area : Find the z-score corresponding to the given area. Remember, z is distributed as the standard normal distribution with mean of 0 and standard deviation of 1.
Write a python program that contains a main function : Write a PYTHON program that contains a main function and a custom, void function namedshow_larger that takes two random integers as parameters.
Asks the user for the number of males and number of females : Write a program that asks the user for the number of males and the number of females registered in a class using two separate inputs.
Mean anxiety score in elementary school children : The mean anxiety score in elementary school children is 14.55. A researcher wants to know if children of anxious parents are more anxious than the average child
Write a program that counts how often each word occurs : Write a program that counts how often each word occurs in the supplied text file mary.txt.
What is the probability that the coin you picked is the fair : Given this information, what is the probability that the coin you picked is the fair one?
Write a function to append lines to a file : Write a function to append lines to a file. Do this in a loop that would allow the user to continue adding lines to a file until they enter the letter q.

Reviews

Write a Review

Python Programming Questions & Answers

  Implement your algorithm in python

Write an algorithm in structured English (pseudocode) that describes the steps required to perform the task specified and reinforce topic material related to the programming work cycle, and the input, processing, output program structure.

  Write a python program for grocery list manager

Write a python program for grocery list manager and note taking system that has note taking mode and grocery listing mode.

  Python journeyman

What are the steps YOU would recommend to a Python journeyman, from apprenticeship to guru status?

  A string is valid windows filename.

writing a function in python that verifies whether a string is valid windows filename.

  Write a program that asks for the user age

Write a program that asks for the user's age. Based on their response print "You can vote" (18 years old or older) or "You can't vote" and also whether or not he/she is a senior citizen (over 64)

  Enter an integer for the base of the power

This assignment requires one file containing a main function and a recursive function named power.

  Develop program that randomly generate shakespearean insults

Assignment: Shakespearean Insults- Develop a program that will randomly generate twenty Shakespearean insults using the lists of words in the table below.

  Develop python script that will implement the given command

Write a python script that will implement the following command: merge sourcedirectory1 sourcedirectory2 destinationdirectory

  How does the a developed program work

How does the a developed program (By Python) work which looks for the words "subsidies" and "grants" and download from all Thomson Reuters Reports.

  Describe the properties of the class

Describe the properties of the class and any constraints upon their value. Indicate where the algorithms defined in processing logic are implemented.

  Function should return a dictionary

Write a function numOccur(s), where s is a string; the function should return a dictionary whose keys are the 26 ascii letters abcdefghijklmnopqrstuvwxyz

  Write a python expression that given the variable inputstr

Write a Python expression (or script) that, given the variable inputStr, set as: inputStr = "The quick brown fox jumps over the lazy dog".

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