Write a program flowchart

Assignment Help Data Structure & Algorithms
Reference no: EM13167953

Write a program FLOWCHART that lets the user enter a sequence of numbers. The program should stop when it notices that the last two numbers entered were identical. At this point, it should report how many entries were made. For example, the user could enter the following sequence:

44
9
93
94
44
2
44
104
104

after which the program would stop and output 9 (because the user made 9 entries).

Note that the program is not counting distinct numbers entered - if the same number is entered multiple times, it should be counted multiple times. The user should NOT be asked for the length of the sequence in advance. The length of the sequence is up to the user and will not necessarily be a multiple of 3.

Your program may use the following operations:

  • Output information (text, numbers, etc.)
  • Input a real number, integer, or boolean value
  • Store a numeric or boolean value into a variable
  • Perform arithmetic operations: add, subtract, multiply, divide, integer quotient, integer remainder
  • Perform numeric comparisons: equals, does not equal, less than (or equal to), greater than (or equal to)
  • Perform boolean operations: and, or, not
  • Make decisions
  • Loop (go back to an earlier point in the program)

 

 

Reference no: EM13167953

Questions Cloud

What is the ph of a buffer system : What is the pH of a buffer system that contains 0.240 M hydrocyanic acid HCN and 0.190 M sodium cyanide NaCN? The pKa of hydrocyanic acid is 9.31.
State what is the ph after naoh : A buffer containing 0.4316M of acid, HA, and 0.1549M of its conjugate base, A- has a pH of 2.20. What is the pH after 0.0019 mol NaOH
What value is obtained for the ka of acetic acid : What is the concentration of the vinegar in weight percent? (Assume a density of 1.030 g/mL.) If the pH of the vinegar was 3.44, what value is obtained for the Ka of acetic acid?
Suppose that the density of the mixed solutions : Assume that the density of the mixed solutions is 1.00 g/mL, that the specific heat of the mixed solutions is 4.18 J/(g celcius), and that no heat is lost to the surroundings. The deltaHrxn for the neutralization of NaOH with H2SO4 is -114 kJ/mol ..
Write a program flowchart : Write a program FLOWCHART that lets the user enter a sequence of numbers. The program should stop when it notices that the last two numbers entered were identical.
Compute the volume of naoh that will be needed : A student plans to titrate 25 mL of a .134 M HNO3 solution with .179 M NaOH solution. Calculate the volume of NaOH that will be needed to reach equivalence point.
Create a new file called week3prog3 : Linux® Script 3 Requirements In the same folder as last week, create a new file called week3prog3[name].scr. Change the permissions on this new file to add the execute bit for user, group, and owner
Explain what is the final temperature of the mixture : degree C is mixed with 35.2 g/mL of water (density = 1.0 g/mL) initially at 24.4 degree C in an insulated beaker. Assuming that no heat is lost, what is the final temperature of the mixture?
Explain how much ice is required to cool : When ice melts, it absorbs 0.33 kJ per gram. How much ice is required to cool a 13.0 oz drink from 74 degree F to 31 degree F

Reviews

Write a Review

Data Structure & Algorithms Questions & Answers

  Prepare a japplet with a jbutton

Prepare a JApplet with a JButton labeled Who is number one and when the user clicks on button, display your favorite sports team. Save the document as JNumberOne.java.

  Give algorithm-correctness proof-time complexity for tree

Determine the minimum number of nodes in tree to remove so that the tree is separated into subtrees of sizes at most k. Give the algorithm, the correctness proof and the time complexity.

  Finding time taken to send packet from source to destination

Think about sending a document of F bytes over a path of Q links. Each link transmits at R bps. The network is lightly loaded so that there are no queuing delays.

  Question related to bash script

Create a shell script to send a customized mail memo to the users listed on the command line through login name, only if they are currently logged on.

  Build a binary search tree

Build a binary search tree using the following set of numbers, preserving the orderin which they are given: 34,26,47,22,28,10,24,38,51,49,37,4,45,60,57,14.

  Cost control techniques

Assume your company has just completed the Initiation Process for implementing an Email System Upgrade. It was identified in a recent meeting with management leaders from the Sales,

  Graph theory

Let  A  be a graph that has an Euler circuit. Prove (or disprove) that all graphs that are isomorphic to  A  have at least on Euler circuit.

  Order statistic tree to count number of inversions in array

Demonstrate how to use an order-statistic tree to count the number of inversions in an array of size n in time O(n lg n).

  Explaining simple symmetric encryption algorithm

Consider a simple symmetric encryption algorithm as follows:Is it a problem if the first block of input happens to be the same as the key? Explain why?

  Find values of n insertion sort beat merge sort

For inputs of size n, insertion sort runs in 8n 2 steps, where as merge sort runs in 64* nlog base 2 n steps. For which values of n odes insertion sort beat merge sort?

  Creating sql statements

Create three SQL statements: the 1st statement should add pending amounts to appropriate accounts, the second statement should subtract the pending amounts from appropriate accounts,

  Question about hardware requirements

When you purchase a new software package, why does it state minimum RAM and hard drive space your computer must have for you to run this program?

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