Loading...

Messages

Proposals

Stuck in your homework and missing deadline? Get urgent help in $10/Page with 24 hours deadline

Get Urgent Writing Help In Your Essays, Assignments, Homeworks, Dissertation, Thesis Or Coursework & Achieve A+ Grades.

Privacy Guaranteed - 100% Plagiarism Free Writing - Free Turnitin Report - Professional And Experienced Writers - 24/7 Online Support

Flowchart and pseudocode of program that doubles a number

04/12/2021 Client: muhammad11 Deadline: 2 Day

COLLEGE OF BUSINESS ADMINISTRATION

FALL 2017/2018

MISY 2312: Introductory to Programming

Credit Hours: 3.00

Final Project (30%)

Group Project

Instructor: Ms. Darin ElNakla

Due Date: 14/DEC/2017

Office number: F92

Email: delnakla@pmu.edu.sa

Tel No: 038498868

1. Draw a flowchart for the following:

a. Draw a flowchart or write pseudo code to represent the logic of a program that allows the user to enter a value. The program divides the value by 2 and outputs the result.

Start

Input myNumber

set myAnswer = myNumber/2

output myAnswer

b. Draw a flowchart or write pseudo code to represent the logic of a program that allows the user to enter a value for one edge of a cube. The program calculates the surface area of one side of the cube, the surface area of the cube, and its volume. The program outputs all the results.

start

input cubeSide A

set cubeSide A area = cubeSide A * cubeSide A

set totalSurFaceArea = 6 * cubeSide A area

set cubeVolume = cubeSide A * cubeSide A * cubeSide A

output cubeSide A area

output cubeVolume

output totalSurFaceArea

stop

c. Draw a flowchart or write pseudo code to represent the logic of a program that allows the user to enter two values. The program outputs the product of two values.

Start

Input number3

Input number7

Set answer = number3 * number7

Output answer

Stop

d. Draw a typical hierarchy chart for a program that pseudo code a monthly bill for a cell phone customer. Try to think of at least 10 separate modules that might be included. For example, one module might calculate the charge for daytime phone minutes used.

e. Draw a structured flowchart or write structured pseudo code describing how to do a load of laundry. Include at least two decisions and two loops.

Start

open washing machine door

while dirty clothes in the hamper is true

put dirty clothes in washing machine

endwhile

pour in detergent

if this is a cold load then

set temperature to cold

else

set temperature to warm/hot

endif if

fabric softener is needed then

pour in fabric softener

endif

close washing machine door

start washing machine

while the washing machine is running is true

wait for load to finish

endwhile

stop

f. Design a flowchart or pseudo code for a program that accepts two numbers from a user and displays one of the following messages: First is larger, Second is larger, Numbers are equal.

Start

Input first,second

If first is greater than second then

Output ”first is larger”

else

Output “second is larger”

If first=second then

Output “numbers are equal”

End if

Stop

2. Answer the following:

a. What output is produced by the following code fragment? Explain.

i. System. out. print(“Java ”)

System. out. print(“Programming”);

ii. System. out. println(“Java ”)

System. out. println(“Programming”);

b. Write a single Java program statement to display the text below and explain why it is written like that.

“A piano has

88 keys”

c. What output is produced by the following code fragments?

i. System. out. println (“Result : “+ 40+30);

ii. System. out. println (“Result : “+ (40+30));

d. What output is produced by the following code fragments?

i. System. out. println(“A \ “lable\ “ can contain either \n\ttext,

\n\tan image, or \n\tboth. ”);

e. What value is contained in the integer variable value after the following statements are executed?

value=16;

value=value+5;

value=value+1;

value=value/3;

f. What result is contained in the integer variable value after the following statements are executed?

value=10;

value +=10;

value *= value;

value /= value;

value -=10;

g. Given the following decelerations, what result is stored in each of the listed assignment statements?

int iResult, num1 = 25, num2 = 40, num3 = 17, num4 = 5;

double fResult, val1 = 17.0, val2 = 12.78;

i. iResult = num1 / num4;

ii. fResult = num1 / num4;

iii. iResult = num3 / num4;

iv. fResult = num3 / num4;

v. fResult = val1 / num4;

vi. fResult = val1 / val2;

vii. iResult = num1 / num2;

viii. fResult = (double) num1 / num2;

ix. fResult = num1 / (double) num2;

x. fResult = (double) (num1 / num2);

xi. iResult = (int) (val1 / num4);

xii. fResult = (int) (val1 / num4);

xiii. fResult = (int) ((double) num1 / num2);

xiv. iResult = num3 % num4;

xv. iResult = num2 % num3;

xvi. iResult = num3 % num2;

xvii. iResult = num2 % num4;

3) Write a Java statement to accomplish each of the following tasks:

a) Declare variables sum and x to be of type int.

b) Assign 1 to variable x.

c) Assign 0 to variable sum.

d) Add variable x to sum, and assign the result to variable sum.

e) Print “The sum is: “, followed by the value of variable sum.

a) int sum, x; b) x = 1; c) sum = 0; d) sum += x; or sum = sum + x; e) printf("The sum is: %d\n", sum);

4) Combine the statements that you wrote into a Java application that calculates and prints the sum of integer from 1 to 10. Use the while loop through the calculation and increment statements. The loop should terminate when the value of x become 11.

5) Write a java statement or a set of java statements to accomplish each of the following tasks:

a) Sum the odd integers between 1 and 99, using a for statement. Assume that the integers variables sum and count have been declared.

b) Calculate the value of 2.5 raised to the power of 3 using the pow method.

c) Print the integers from 1 to 20, using the while loop the counter variable i. Assume that the variable it has been declared, but no initialized. Print only five integers per line. [ Hint: Use the calculation i % 5. When the value of this expression is 0, print a newline character; otherwise, print a tab character. Assume that this code is an application. Use System.out.println(‘\t’)method to output the tab character .]

d) Repeat part (c), using for statement

1-

int sum;

int counter;

sum = 0;

for (counter = 1; counter <= 99; counter += 2)

sum += counter;

cout << "Sum of odd integers between 1 and 99 is: " << sum << endl << endl;

2-

value = pow (2.5, 3);

cout << fixed << setprecision (2) << setw (10) << value << endl << endl;

3-

int x;

x = 1;

while (x <= 20)

cout << x;

if (x % 5 == 0)

cout << "\n";

else

cout << "\t";

x++;

cout << endl;

4-

for (x = 1; x <= 20; x++)

cout << x;

if (x % 5 == 0)

cout << "\n";

else

cout << "\t";

cout << endl;

6) Write a java program that displays a student's status based on the following codes: Code Student Status 1 Freshman 2 Sophomore 3 Junior 4 Senior Your program should accept the code number as a user-entered input value and based on this value display the correct student status. If an incorrect code is entered, your program should display the string "An incorrect code was entered".

switch (code)

{

case 1:

status = "Freshman";

break;

case 2:

status = "Sophomore";

break;

case 3:

status = "Junior";

break;

case 4:

status = "Senior";

break;

produceCellPhoneBill()

computeTaxes()

calcLocalTax()

calcStateTax()

getUsageInfo()

computerText()

getCustomerInfo()

computerCalls()

printBill()

calcFedTax()

Homework is Completed By:

Writer Writer Name Amount Client Comments & Rating
Instant Homework Helper

ONLINE

Instant Homework Helper

$36

She helped me in last minute in a very reasonable price. She is a lifesaver, I got A+ grade in my homework, I will surely hire her again for my next assignments, Thumbs Up!

Order & Get This Solution Within 3 Hours in $25/Page

Custom Original Solution And Get A+ Grades

  • 100% Plagiarism Free
  • Proper APA/MLA/Harvard Referencing
  • Delivery in 3 Hours After Placing Order
  • Free Turnitin Report
  • Unlimited Revisions
  • Privacy Guaranteed

Order & Get This Solution Within 6 Hours in $20/Page

Custom Original Solution And Get A+ Grades

  • 100% Plagiarism Free
  • Proper APA/MLA/Harvard Referencing
  • Delivery in 6 Hours After Placing Order
  • Free Turnitin Report
  • Unlimited Revisions
  • Privacy Guaranteed

Order & Get This Solution Within 12 Hours in $15/Page

Custom Original Solution And Get A+ Grades

  • 100% Plagiarism Free
  • Proper APA/MLA/Harvard Referencing
  • Delivery in 12 Hours After Placing Order
  • Free Turnitin Report
  • Unlimited Revisions
  • Privacy Guaranteed

6 writers have sent their proposals to do this homework:

Top Class Engineers
Essay Writing Help
Instant Homework Helper
Top Rated Expert
Top Class Results
Finance Master
Writer Writer Name Offer Chat
Top Class Engineers

ONLINE

Top Class Engineers

After reading your project details, I feel myself as the best option for you to fulfill this project with 100 percent perfection.

$41 Chat With Writer
Essay Writing Help

ONLINE

Essay Writing Help

As an experienced writer, I have extensive experience in business writing, report writing, business profile writing, writing business reports and business plans for my clients.

$22 Chat With Writer
Instant Homework Helper

ONLINE

Instant Homework Helper

I have read your project details and I can provide you QUALITY WORK within your given timeline and budget.

$18 Chat With Writer
Top Rated Expert

ONLINE

Top Rated Expert

After reading your project details, I feel myself as the best option for you to fulfill this project with 100 percent perfection.

$19 Chat With Writer
Top Class Results

ONLINE

Top Class Results

I will provide you with the well organized and well research papers from different primary and secondary sources will write the content that will support your points.

$26 Chat With Writer
Finance Master

ONLINE

Finance Master

I will be delighted to work on your project. As an experienced writer, I can provide you top quality, well researched, concise and error-free work within your provided deadline at very reasonable prices.

$45 Chat With Writer

Let our expert academic writers to help you in achieving a+ grades in your homework, assignment, quiz or exam.

Similar Homework Questions

Tara yosso critical race counterstories - Which statement least characterizes the abolitionist movement in america - Short essay question need finished in 1 hour and half - Letter 1: Routine Reply/Positive Message - Project work breakdown structures and coding systems - Metrolina comprehensive health center - What is naturalistic observation in psychology - What is the blinking line called in word - Introduction to Marketing- case briefing - Discussion 1 - Royal canin breeders club - Liebert ac power system - Wk 1, IOP 490: Program Evaluation and Reflection - I need 1200 words total (3 pages 1.5 spacing) on BASED UPON THE PAPERS AND LECTURES, PLEASE COMPARE BRIEFLY SOCIAL MARKET - Political artists like banksy - Policy Analysis Paper - “reading response” - Behavior modification project research paper - ME - Online - Dis 2 - 9 kinedana street eden hills - Employment Discrimination Discussion - Taxi driver shootout scene - What makes a poem romantic - Religious Discrimination: Reasonable Accommodations - ACCT Report - Digital forensics - What does the trial balance tell you - Loeb drama center view from my seat - Is a manatee a herbivore or carnivore - Truth in sentencing debate - Acceptable behaviour in the workplace - Minutely ground substance crossword 6 letters - Hsc economics exchange rates essay - What is a professional learning community by richard dufour - How to calculate usual body weight - Don sabo pigskin patriarchy and pain - Style lessons in clarity and grace pdf - Should Social Media Activity Cost You a Job? - Inclusive language effect on reader - Company policies - Organizational behaviour topics for presentation - Wilsons prom lighthouse accommodation - Critical analysis - Edu gcfglobal en excel 2016 - Example of an autobiography of a student - Daphnia magna heart rate lab report - Raspberry pi ecu simulator - Questioon - Potassium hydrogen phthalate buffer preparation - Jean watson carative factors definition - Afls independent living skills pdf - Is 1000 ml a liter - Profithr admissions multiple mini interview - What is missing in this particular stanza of the erlking - Delimitation of the study example - Overall process of developing new software - International journal of lean six sigma - DQ#222222NRNP - Which countries have banned mobile phones in schools - Suppose the supply function for product x is given by qxs = - 30 + 2px - 4pz. - Martin luther king and malcolm x worksheet - 5 page APa Strategic plan appraisal - Digital, Microwave and Optical Communications - Systems understanding aid 9th edition - English answer question - The great italian trivia game - When does h&m get new shipments - Patricia benner novice to expert model - 1 Discussion - Problem set - Assignement - Lamtec wmp 50 installation instructions - Flight paramedic job description - Acid catalyzed dehydration of cyclohexanol - Freight equalization pros and cons - Should the pledge of allegiance have under god - Cultural artifact speech - Time warner inc investor relations - Essay - What are five recommended steps to make ethical decisions - Cornell notes example history - Erm adoption and implementation in the higher education environment - Reflection paper - Who are the main characters in the lottery - Week 9 enivorment - Change management discussion questions - Siemens insight user manual - 1000 point grading scale snhu - Mba 104 assignment answers - Estonia homework - Virginia held ethics of care sparknotes - Openwhisk serverless environment - Discussion #1 - Tell us about a "causal study" you've been involved in. - Canvas sydney edu au - Translational Research And Population Health Management - Obb and bob phase 5 - Gungahlin child and family centre - Science Meets Real Life - Marty grims net worth - Company's positive experience with implementing erp - Timeline of 100 years war - Share a coke campaign metrics