Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

* * * i need help idk how to do this can you give me step by step with screen shots on how to do

*
*
*
i need help idk how to do this can you give me step by step with screen shots on how to do this
*
*
Instructions
The following exercises will demonstrate your ability to apply Python variables, data types, and operators by
addressing the programming problems given to you. Please create the following programs in Python.
For each of the following questions, create a separate .py file for it. After completion, submit the four .py files
and a screenshot showing the result of each programs execution.
File 1: [
operators.py]
Write a program to output the results of using the modulus operator % and the floor division operator // in
arithmetic expressions. Using five print () functions with f-strings to display the results. For each line of the
outputs, the left operand of the operators is 491857, and the right operands are 10,100,1000,10000, and
100000 respectively. The output should look like this:
Knowing how % and // work will help you answer the next few questions.
File 2: [
separation1.py]
Write a Python program that asks users to input a 6-digit integer. The program will then separate the integer into
individual digits. Print the digits out and separate them by the hyphen (-) character. For example:
Please use % and ??? operators to complete this task.
File 3: [
separation2.py]
Same as the previous question, but this time please use string slicing to complete this task.
File 4: [
dollars.py]
Create a Python program that asks its user to provide the number of quarters (25 cents), dimes (10 cents), nickels
(5 cents), and pennies (1 cent) they have. Afterward, output the total amount of dollars and cents the user has.
For example: How many dimes do you have?: 3
How many nickels do you have?: 28
How many pennies do you have?: 6
The total amount you have is 426 cents, which is equivalent to 4 dollars and 26 cents.As:How many dimes do you have?: 2
How many nickels do you have?: 3
How many pennies do you have?: 4
The total amount you have is 64 cents, which is equivalent to 0 dollars and 64 cents.
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Expert Performance Indexing In SQL Server

Authors: Jason Strate, Grant Fritchey

2nd Edition

1484211189, 9781484211182

More Books

Students also viewed these Databases questions

Question

1. Make sure you can see over partitions.

Answered: 1 week ago