Ask the user to enter a positive integer greater than zero

Assignment Help Computer Engineering
Reference no: EM132207522

Write a program which:

1. Asks the user to enter a positive integer greater than 0

2. Validates that the entry is a positive integer

3. Outputs the digits in reverse order with a space separating the digits

4. Outputs the even digits not in reverse order with a space separating the digits (consider zero to be even)

5. Outputs the odd digits not in reverse order with a space separating the digits

6. Allows user is to repeat/continue the program as many times as he/she wants

7. Keeps a record in a txt file named outDataFile.txt with the history of all numbers entered and the associated results, in the following format: In addition:

8. The program must have the following four void methods:

a. validate //validate user input

b. reverse // output reverse digits to screen and txt file

c. even //output even digits to screen and txt file

d. odd //output odd digits to screen and txt file GENERAL RESTRICTIONS FOR this homework:please follow these instructions when doing this: no loops please redo the homework,

1. No infinite loops, examples include:

a. for(;;)

b. while(1)

c. while(true)

d. do{//code}while(1);

2. No break statements to exit loops i need it by tommarow afternoon, thanks, the homework has to be done in the programming language java, also please do not include while infinite loops please!, please write the code in java and no infinite loops please,esp. while infinite loop.

Reference no: EM132207522

Questions Cloud

Would you choose sure amount or the right to open the boxes : Assuming that your utility function is U(x) = (x)1/2 (square root of x), and that you use expected utility as your guide in life, would you choose.
Find nash equilibrium bid and ask prices : Draw the trading network, with the trader as a square, the buyers and the sellers as circles, and the edges representing pairs of people who are able to trade.
What is the marginal product of the heathen : A pastor converts heathens (h) into reformers (r) by offering them a prayer (p). In order to produce 1 reformer (r), the pastor must have both a heathen.
Compute the subgame perfect equilibrium : You (Y ) have a job offer by Microsoft that pays a wage of r. But you have also a job offer from Facebook (F) and are in the process of negotiating your wage w.
Ask the user to enter a positive integer greater than zero : Outputs the even digits not in reverse order with a space separating the digits (consider zero to be even).
What the possible nash equilibrium outcomes are : Consider a trading network with intermediaries in which there is one buyer, one seller and two traders (intermediaries). The buyer and the seller each are.
Accept a number of minutes and converts it both to hours : Write a program that accepts a number of minutes and converts it both to hours and days.
Find the optimal size of the hot tub group : Find the optimal size of the hot tub group, and give an explanation of why it differs from the equilibrium size. Next compute the grand total of benefits.
Write a php script that checks a word or a phrase : Write a PHP script that checks a word or a phrase (stored in a string variable) to determine if it is a standard palindrome.

Reviews

Write a Review

Computer Engineering Questions & Answers

  Mathematics in computing

Binary search tree, and postorder and preorder traversal Determine the shortest path in Graph

  Ict governance

ICT is defined as the term of Information and communication technologies, it is diverse set of technical tools and resources used by the government agencies to communicate and produce, circulate, store, and manage all information.

  Implementation of memory management

Assignment covers the following eight topics and explore the implementation of memory management, processes and threads.

  Realize business and organizational data storage

Realize business and organizational data storage and fast access times are much more important than they have ever been. Compare and contrast magnetic tapes, magnetic disks, optical discs

  What is the protocol overhead

What are the advantages of using a compiled language over an interpreted one? Under what circumstances would you select to use an interpreted language?

  Implementation of memory management

Paper describes about memory management. How memory is used in executing programs and its critical support for applications.

  Define open and closed loop control systems

Define open and closed loop cotrol systems.Explain difference between time varying and time invariant control system wth suitable example.

  Prepare a proposal to deploy windows server

Prepare a proposal to deploy Windows Server onto an existing network based on the provided scenario.

  Security policy document project

Analyze security requirements and develop a security policy

  Write a procedure that produces independent stack objects

Write a procedure (make-stack) that produces independent stack objects, using a message-passing style, e.g.

  Define a suitable functional unit

Define a suitable functional unit for a comparative study between two different types of paint.

  Calculate yield to maturity and bond prices

Calculate yield to maturity (YTM) and bond prices

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