Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Computer Engineering Expert

Question: Although the subsequent code compiles and runs, the programmer broke some major readability rules.

Describe at least three changes that would make it easier for other programmers to read and understand the code.

class Program { static void Main() //TBD

{

   double count;

   double Double = 10; // declare variables

   for(int i = 0;i < Double;i++) //keep doing

        {

            count=function(i);

            Console.WriteLine(count);

        }

        Console.Read();

        }

        public static double function(int a) //a function

        {

        return (Math.Sqrt(a));

        }

   }

I am having difficulty with this program because I do not know where to start with.

Computer Engineering, Engineering

  • Category:- Computer Engineering
  • Reference No.:- M91245983

Have any Question?


Related Questions in Computer Engineering

Give a recursive algorithm that generates a similar series

Give a recursive algorithm that generates a similar series of coins for changing n cents. Don't use dynamic programming for this problem.

A a simple encryption of a character a can be performed by

a) A simple encryption of a character A can be performed by exclusive-ORing A with some key K to produce the encrypted value E. The original value A can be recovered by exclusive-ORing again with the same key. Write a c/ ...

If we compare and contrast the four market structures it is

If we compare and contrast the four market structures, it is evident that one market structure is most practiced and evident in the United States. It is the one that promotes and strives on competition. It is the one tha ...

Assignment week 5 user acceptance testinguser acceptance

Assignment: Week 5 User Acceptance Testing User acceptance testing, or UAT, is a round of testing in which the users who are expected to use the system after it goes live exercise the system. UAT differs from quality ass ...

Question suppose you have two arrays of 8-bit signed

Question : Suppose you have two arrays of 8-bit signed integers P[i] and Q[i] for 0 = i A pointer to the array P is passed in register X and a pointer to the array Q is passed in register Y. The number of elements in eac ...

Sally goes into a candy store and selects 12 pieces of

Sally goes into a candy store and selects 12 pieces of taffy. The candy store offers 75 varieties of taffy. How many ways are there for Sally to select her 12 pieces of taffy?

Explain that the biggest problems with adware is that it

Explain that the biggest problems with adware is that it slows down the computers its running on.

Question suppose you are the analyst charged with

Question : Suppose you are the analyst charged with developing a new system to help senior managers make better strategic decisions. What methodology would you use? How would the business strategy affect your approach? W ...

Question suppose that during the playing of the

Question : Suppose that during the playing of the coins-in-a-line game that Alice's opponent, Bob, makes a choice that is suboptimal for him. Does this require that Alice recompute her table of remaining Mi,j values to p ...

Suppose pointers are 4 bytes long and keys are 12 bytes

Suppose pointers are 4 bytes long, and keys are 12 bytes long. How many keys and pointers will a block of 16,384 bytes have?

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As