Ask a New Question

Asked by Raj

WAP to reverse an array of integers in VBA.

Dim a(5), n As Integer
Dim b = 0, e = n - 1, temp As Integer
Console.WriteLine("Enter a no.")
For n = 0 To 5
a(n) = Console.ReadLine()
Next

For b = 0 To n / 2
temp = a(b)
a(b) = a(e)
a(e) = temp
e = e - 1
Next

For e = n To 0
Console.WriteLine(a(e))
Next
Console.ReadLine()

Where I have done mistakes, please correct my code.
5 years ago

Answers

Related Questions

I don't know how to reverse cosine decimals into angles. Can you please explain and help me solve th... 9.10: Reverse Array Write a function that accepts an int array and the array’s size as arguments.... 1.Can an object reverse its direction of travel while maintaining a constant acceleration? If so, gi... when do you reverse an inequality sign? As an example of how reverse splits work, ProShares Ultrashort Silver (ZSL) underwent a 1-10 reverse... 5 - 6x = -7 do reverse P.E.M.D.A.S and explain. 1/3p + 8 = 17 Use reverse Pemdas 27h + 1/2 = 59 Use reverse Pemdas do you reverse the inequality? What can humans do the reverse biodiversity decline? Pick one Increase, urban development...
Ask a New Question
Archives Contact Us Privacy Policy Terms of Use