Program of 2d byte array dynamicall, C/C++ Programming

In this lab, please complete a given program to perform the following tasks:

1. Allocate a 10 by 5 2D byte array dynamically. The way of allocation must be consistent with page 39 in chap9.ppt. Each element is a byte.

2. For each element in the array, assign a random number. The range does not matter.

3. Display the array.

4. Exchange the rows as defined below:

Row 0 becomes Row 9
Row 1 becomes Row 0
Row 2 becomes Row 1
Row 3 becomes Row 2
Row 4 becomes Row 3
Row 5 becomes Row 4
Row 6 becomes Row 5
Row 7 becomes Row 6
Row 8 becomes Row 7
Row 9 becomes Row 8
Please swap the values, instead of just the pointers.

5. Display the array.

You are required to finish the given program, "TwoDArray_lab6.asm", without adding new variables. The output may look like:

2344_output of array.png

Posted Date: 3/25/2013 6:23:30 AM | Location : United States







Related Discussions:- Program of 2d byte array dynamicall, Assignment Help, Ask Question on Program of 2d byte array dynamicall, Get Answer, Expert's Help, Program of 2d byte array dynamicall Discussions

Write discussion on Program of 2d byte array dynamicall
Your posts are moderated
Related Questions

Program to Open a file in C++: int main() {                  char ch;                  ifstream f1 ("OLDFILE.TXT");                  ofstream f2 ("NEWFILE.TXT");

A palindrome is a string that reads the same from both the ends. Given a string S convert it to a palindrome by doing character replacement. Your task is to convert S to palindrome

Are comments included during compilation stage and placed in EXE file as well? - No, comments encountered by compiler are disregarded. - Their only purpose is ease and guida

Byteland county is very famous for luminous jewels. Luminous jewels are used in making beautiful necklaces. A necklace consists of various luminous jewels of particular colour. Nec

Suppose we use Lists to represent a movie which has a title, cast and year. For example, the following list represents the movie, "Die Hardly", with the cast "Bruce Willing" and "T

padovan string for n natural numbers p(n)=1,p(n)=2,p(n)=3 and use padovan formul to get output 1

Conversion from Basic to User-Defined variable Consider the following example. class Distance                  {                   public  :

1. When developing this project in a Win32 Console Applications that includes the precompiled headers, enter in the Name: box, PRJ2[Your Full Last Name][Your First Initial] with no

Default Value Functions,  When declaring a function we can specify a default value for each parameter. This value will be used if that parameter is left blank when calling to the f