Array user interface, Computer Engineering

You were offered bonus marks for separating the user interface code from the main logic of your program. This design choice makes it very easy to replace the user interface without having to change the main program logic.

Make a copy of the class BasicUI, called ArrayUI. Within ArrayUI, make sure all references to BasicUI are renamed to ArrayUI.

In this task, you will modify the updateScreen() method of class ArrayUI to print out two lines in the following format:



This line gives a spatial view of where the all of the objects are. For example, the player, represented by "P" is at position 4 and is holding stone "%". The treasure chest "X" is at position 5. The stone "#" is still on the ground at position 1. This task must be implemented using two arrays of chars in class ArrayUI. The first array, called sky will hold the array of characters representing {‘.','.','.','.','%','.'} and the second array, called ground, will hold the array of characters representing {‘_','#','_','_','P','X'}. Of course, the actual characters found in the array will change as the game progresses.

Posted Date: 3/25/2013 5:52:23 AM | Location : United States

Related Discussions:- Array user interface, Assignment Help, Ask Question on Array user interface, Get Answer, Expert's Help, Array user interface Discussions

Write discussion on Array user interface
Your posts are moderated
Related Questions
Explain various threats posed through servers into a client server environment. Server Destroyed within an Accident: Power failures, Leaking pipes and equipment failures are no

Solve the equation 23.6 10 = X 2 for X Ans. 23.6 10 = X 2 So as to find X, firstly convert the Decimal number 23.610 in its Binary form. After that take the decimal inte

Discuss two main approaches to reuse free memory area in a heap. Two major approaches to reuse free memory area in a heap are: First-fit: Allocate the first hole which i

Explain how SAP GUI handles output screen for the user. The SAP front-end s/w can either run on the similar computer or on dissimilar computers given for that purpose.  User t

Conventionally software has been written for serial computation in that programs are written for computers which have a single Central Processing Unit (CPU). Here the problems are

What is View? A simple view can be thought of as a subset of a table. It can be used for retrieving data, as well as updating or deleting rows. Rows updated or deleted in the v

Minimize the logic function F(A, B, C, D) = ∑ m(1,3,5,8,9,11,15) + d(2,13) using NOR gates with help of K-map. Ans. Realization of given expression by using NOR gates: In POS

Q. What is Block size of cache memory? Block Size: Block size means unit of data (few memory words) exchanged between main and cache memory. As block size increases from very

How many services are supported by internet? The firewall software assists at least Internet services: HTTP, FTP, Gopher, SMTP and Telnet. DNS name resolution, preferably th

Q. How to select a table? The easiest way to select a table in Standard view is by using tag selector, which displays HTML tags of elements in document. You will use tag sel