Question

In: Computer Science

You can estimate the total number of text messages you send and receive in a year...

You can estimate the total number of text messages you send and receive in a year as follows:

  • Count up the number of text messages sent and received during the one-hour period of a typical day when you do the most texting; then ...
  • Multiply that count by 13, and multiply that result by 365, the number of days in a year.

13 is a guesstimate or SWAG for the ratio of the total number of messages sent and received in a day to the number of messages sent and received during the peak hour of texting activity.

Design a program, using pseudocode or a flowchart, that asks the user to enter the number of text messages sent and received for their peak one-hour of texting on a typical day. Use that value to calculate and report out an estimate of how many text messages that person sends and receives in a year.

To get full credit for this problem you must use a named constant for the number of days in a year and a named constant the 13 total day to peak hour ratio. If you believe you have a better guess for that ratio go ahead and use it.

Second Part: Write a Python program based on your design for estimating yearly text messages per the prior problem statement.

Solutions

Expert Solution

Hi,

Please find the pseudocode below.

1>This program will calculate the number of messages sent and received in an year.
2> Take the no of messages sent and received in a day from user as integer input.
3> Take 13 as the count as an estimate to no of messages send and received in a day.
4> Take 365 as a constant which is number of days in a year.
5> Finally no of messages in year = userInputofnoofdays*13*365.
6> display the final no of messages calculated.

Python program below:

print("Program to calculate total no of messages sent in an year")
input_a = input("Enter the no of text messages sent during peak hours : ")
# type cast into integer
input_a = int(input_a)
# print data type
print(input_a)

SWAGGuesstimate = 13
noOfDaysInAYear = 365

totalNoOfMessagesSentInAYear = input_a*SWAGGuesstimate*noOfDaysInAYear

print("Total no of messages sent in an year =",totalNoOfMessagesSentInAYear)

python code screenshot:

output attached:

Thanks,

kindly upvote


Related Solutions

Write a Python Client/Server Socket Program that will allow you to send text messages between the...
Write a Python Client/Server Socket Program that will allow you to send text messages between the server and client, terminating when the exit is typed on the client. Build the program on your 2-VM’s and get it working. Cut and paste your code below along with screen shots of your program working.
Suppose that you receive on average, 10 text messages during a day. What is the probability...
Suppose that you receive on average, 10 text messages during a day. What is the probability that you receive 25 messages today? Also, that you receive 15 messages during 2 days? 16. On average, there are 3 car accidents between 8 am-11 am at point A. What is the probability that there will be 5 accidents during 9 am-10 am at this place? Also, that there will be 8 accidents during 8 am-12 noon? 17. On average, there are 3...
A study finds that graduate students send a mean of 74 text messages per day with...
A study finds that graduate students send a mean of 74 text messages per day with a standard deviation of 15.2 text message per day while undergraduate students send a mean of 116 text messages per day with a standard deviation of 26.51. Which group, the undergraduate students or the graduate students have more variation in the number of sent text messages? Undergraduates, because their standard deviation is higher Undergraduates, because their standard deviation is lower Graduate students, because their...
1. A survey of 1000 drivers found that 29% of the people send text messages while...
1. A survey of 1000 drivers found that 29% of the people send text messages while driving. Last year, a survey of 1000 drivers found that 17% of those sent text messages while driving. (Show your work without using software to solve) a. Give a 95% confidence interval for the increase in text messaging while driving. b. At α = .05, can we conclude that there has been an increase in the number of drivers who text while driving? State...
Assuming that on average college students in the U.S. send 120 text messages per day. A...
Assuming that on average college students in the U.S. send 120 text messages per day. A researcher wants to examine if the amount of text messages sent daily by UNC students differs from the national average. The researcher took a sample of 64 UNC students, and finds that the mean number of texts per day is 126 with a standard deviation of 24. Use alpha .05 a) Is this a one-tail or two-tail test? Write appropriate hypotheses and assumptions. b)...
Email was originally designed to be used to send simple text messages. MIME has enabled the...
Email was originally designed to be used to send simple text messages. MIME has enabled the transfer of complex data types. Comment on the security versus usability of having MIME-enabled email.
Turn the following code into a chat system that can send messages CONTINUOSLY without the the...
Turn the following code into a chat system that can send messages CONTINUOSLY without the the other side needing to a response. Use a send and receive thread to allow this. Client Side: package com.company; import java.io.IOException; import java.net.DatagramPacket; import java.net.DatagramSocket; import java.net.InetAddress; import java.net.SocketException; import java.net.UnknownHostException; import java.util.Scanner; public class Main { public static void main(String[] args) { byte[] receiveBytes = new byte[256]; final String TERMINATE = "bye"; final int SERVER_PORT = 8080; System.out.println("Client started. Type a message and...
A particular telephone number is used to receive both voice calls and fax messages. Suppose that...
A particular telephone number is used to receive both voice calls and fax messages. Suppose that 20% of the incoming calls involve fax messages, and consider a sample of 20 incoming calls. (Round your answers to three decimal places.) (a) What is the probability that at most 5 of the calls involve a fax message? (b) What is the probability that exactly 5 of the calls involve a fax message? (c) What is the probability that at least 5 of...
Question 6 (1 point) The number of text messages sent by a random sample of students...
Question 6 (1 point) The number of text messages sent by a random sample of students at a local university was collected and the following histogram was created: Which of the following statements is likely true: Question 6 options: The distribution of number of text messages sent is approximately symmetric, so the mean is approximately the same as the median. The distribution of number of text messages sent is skewed to the left, so the mean is likely less than...
3. In order to approximate the number of text messages sent daily by Swedish teenagers, Neu...
3. In order to approximate the number of text messages sent daily by Swedish teenagers, Neu Star Communications took a random sample of Swedish youth, finding the number of text messages they sent on a given day in 2018: HOURS 78 86 86 79 84 79 89 86 86 84 79 81 What is the point estimate of the population mean? (Round your answer to 2 decimal places.) ESTIMATED POPULATION MEAN: …..............? Develop a 98% confidence interval for the population...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT