1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Nitella [24]
3 years ago
14

4.3 mini programs AP computer science

Computers and Technology
1 answer:
allochka39001 [22]3 years ago
8 0

1.

name = input("Enter your name: ")

num1 = int(input("Hello "+name+ ", enter an integer: "))

num2 = int(input(name+", enter another integer: "))

try:

   if num1 % num2 == 0:

       print("The first number is divisible by the second number")

   else:

       print("The first number is not divisible by the second number")

except ZeroDivisionError:

   print("The first number is not divisible by the second number")

try:

   if num2 % num1 == 0:

       print("The second number is divisible by the first number")

   else:

       print("The second number is not divisible by the first number")

except ZeroDivisionError:

   print("The second number is not divisible by the first number")

2.

import random, math

num1 = float(input("Enter a small decimal number: "))

num2 = float(input("Enter a large decimal number: "))

r = round(random.uniform(num1, num2), 2)

print("The volume of a sphere with radius " + str(r) + " is " + str(round(((4 / 3) * math.pi * (r ** 3)), 2)))

I hope this helps!

You might be interested in
New Top Level Domains (TLDs) are coordinated by:_______.
Marizza181 [45]
ICANN is the answer
7 0
3 years ago
A system that provides monthly production figures for a manager at manufacturing facility is considered a(n) __________. a. ente
Stolb23 [73]

Answer:

Management information system (MIS)

Explanation:

Most manufacturing companies are organized into levels, with each level having different kinds of information systems. The four major types of systems placed on each organizational level include:

Transactional Processing System (TPS) – Business systems at this level serve at the lowest point of the operational level in an organization. It performs routine transactions like sales entry and payroll.

Management Information Systems – MIS transforms TPS inventory and production data into compressed formats and presented in detailed reports produced as per the agreed schedules to the managers. These reports can be served on a daily, hourly, or monthly basis.

Decision-Support Systems (DSS) – Managers at this level are majorly responsible for making unique and rapidly changing decisions

ESS – It is the strategic level in an organization. Top senior managers use this level to make non-routine decisions that require insight and a lot of judgment.

4 0
3 years ago
Which of the following best explains why some people invest their saving in the stock market and others put their saving in bank
Tanya [424]
The answer to this question is B. Some people feel that the stock market is too risky for them.
7 0
3 years ago
Read 2 more answers
What are TWO examples of soft skills?
Elanso [62]
Computer programming and throubleshooting
3 0
3 years ago
When creating envelopes, how will you adjust the layout?
Burka [1]
It D because I hade this too so it is D
4 0
3 years ago
Read 2 more answers
Other questions:
  • What might be the best response to a cyberbuly attack
    6·2 answers
  • We will pass you 2 inputsan list of numbersa number, N, to look forYour job is to loop through the list and find the number spec
    12·1 answer
  • In the source-code file containing a class's member function definitions, each member function definition must be tied to the cl
    13·1 answer
  • A sentinel value ________ and signals that there are no more values to be entered:____
    14·1 answer
  • Describe the following types of data hazards. RAW WAR WAW
    13·1 answer
  • A third-grade teacher at Potter Elementary School wants a program that allows a student to enter the amount of money a customer
    14·1 answer
  • In the event you get pulled over for a traffic stop, describe the situation from the police officer's perspective and list at le
    6·2 answers
  • Which of the following is true regarding data analysis? a. Disciplines and professions do not provide guidance on data analysis.
    6·2 answers
  • Design a loop that asks the user to enter a number. The loop should iterate 10
    15·1 answer
  • Need help finding the totals and with the empty spots
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!