Write a script to help users calculate compressed file size

Assignment Help Basic Computer Science
Reference no: EM13189406

1. Write a script to help users calculate compressed file size. Prompt the user to enter the original size of a file (inbytes) from the keyboard. Then use the following rules for calculating the compressed file size. Display the result onthe screen.? If the size is less than 5000 bytes, the compression ratio is 90%;? If the size is between 5000 and 50000 bytes, the compression ratio is 70%;? If the size is more than 50000 bytes, the compression ratio is 40%.

2. Develop a small console program driven by a text menu (see the sample screenshot below):? It displays a simple menu with 4 items indicated by number 1-4.? Users will enter number 1 to 4 to run some commands.? Item #1 to #3 will run some shell commands (it's your choice what to run, but do not use the samecommands as in the example). When the command is finished, display the menu again.? If 4 is entered, then quit the program.

Reference no: EM13189406

Questions Cloud

Communicate diagnostic information : Do think there should be mandatory training for physicians and nurses about how to communicate diagnostic information to patients? Explain your answer.
Organizational hierarchies is correct : Which of the following organizational hierarchies is correct?
What is the break-even sales (units) : If fixed costs are $350,000, the unit selling price is $29, and the unit variable costs are $20, what is the break-even sales (units) if the variable costs are decreased by $4?
Syndrome resulting from a robertsonian translocation : Why would Down syndrome resulting from a Robertsonian translocation not be affected by the age of the mother?
Write a script to help users calculate compressed file size : Develop a small console program driven by a text menu (see the sample screenshot below):? It displays a simple menu with 4 items indicated by number 1-4.? Users will enter number 1 to 4 to run some commands.?
Difference between motivation and job satisfaction : What is the difference between motivation and job satisfaction, class? And why should managers be more concerned with motivation than with job satisfaction? Or should they? Why?
Find the size of the labor force in a community : The size of the labor force in a community is 800, and 720 of these folks are gainfully employed. In this community, 200 people over the age of 16 do not have a job and are not looking for work. In addition, 100 people in the community are under t..
What is the temperature of the coffee after 14 minutes : A cup of coffee at 173 degrees is poured into a mug and left in a room at 65 degrees. After 4 minutes, the coffee is 142 degrees. Assume that the differential equation describing Newton's Law of Cooling is (in this case) .
Definition of normal-abnormal vary from culture to culture : How does the definition of normal and abnormal vary from culture to culture? Give examples in our culture (US) where what is considered normal by some is considered abnormal by others.

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Write sequence of statements-find first comma in string line

Write down sequence of statements which finds first comma in the string line, and assigns to variable clause portion of line up to, but not including comma.

  What is the global cpi for each implementation?

Given a program with a dynamic instruction count of 1.0E6 instructions divided into classes as follows: 10% class A, 20% class B, 50% class C, and 20% class D, which implementation is faster?"

  Explaining initial values of cache tags and cache lines

Assuming that the initial values of the cache tags and the cache lines are completely arbitrary, Also, show how the cache tags will change for each of the above steps. You should justify your answer.

  Write code to assign to the variable

Write code to assign to the variable format a formatting string that will display three values referenced by the variables quantity

  Write the diffent entities or objects

Write the diffent entities or objects,logical processes,data flows, and dfata stores which are involoved. starting from time you submitted your time sheet.

  Explain type of impact of bi software on businesses

Visit website of the vendor of your choice and research their BI (Business Intelligence) capabilities. Report to the class on your findings. What type of impact do you think the BI software you researched will have on businesses that make use of it..

  How to make system more user-friendly

What improvements or additions to the system do you believe would advantage you or make system more user-friendly? Why?

  Error detection-correction facility-interpreters- compilers

Compare error detection and correction facilities of interpreters and compilers. Compare static and dynamic linking. With respect to the requirements of modern applications, what are the shortcomings of 3GLs?

  Decision tables and dependency diagrams

Decision Tables and Dependency Diagrams

  Determine minimum number of tapes needed for backups

Days of the week (including the weekend), determine the minimum number of tapes needed to accommodate seven days worth of backups?

  Explaining service strategy or service design

Select a topic that most interests you from Service Strategy or Service Design and then write a paper around that topic. Try to use as much of your own creativity and originality when writing the paper.

  Create direct-mapped data cache for the byte offset

Create the 128KB direct-mapped data cache which uses a 32 bit address and 16 bytes per block. Compute the following: How many bits are utilized for the byte offset?

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