Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

MIPS Program Assignment Three in Computer Architecture CSC 320, Assignments of Computer Architecture and Organization

A programming assignment for a mips program in computer architecture csc 320. The assignment involves writing a program that performs various operations on a two-dimensional array, including initializing the array, printing the value of a particular element, searching for a value, printing the sum of a row or column, and printing the total sum of all elements. The program should use a switch statement to implement these tasks and should not terminate until a 0 is input to quit.

Typology: Assignments

Pre 2010

Uploaded on 08/18/2009

koofers-user-er3
koofers-user-er3 🇺🇸

10 documents

1 / 1

Toggle sidebar

Related documents


Partial preview of the text

Download MIPS Program Assignment Three in Computer Architecture CSC 320 and more Assignments Computer Architecture and Organization in PDF only on Docsity! Program Assignment Number Three Computer Architecture CSC 320 Due February 19, 2008 For your third programming assignment, you are to write MIPS program which will perform the following operations on two dimensional arrays. Initialize a two dimensional array containing the following values: 1 2 3 4 5 10 9 8 7 6 13 54 23 2 6 66,33,82,12,5 22,56,2,9,7 5,0,3,12,74 Write a MIPS program which will perform the following functions in this order: 1. Print the value of a particular array element, if this option is chosen, the program must prompt user for the indices of the element desired. 2. Prompt the user to input a value and search the array, returning a message that the value is either not present or the indices if present 3. Prompt the user to input a row number and print the sum of that row 4. Prompt the user to input a column number and print the sum of that column 5. Print the total of all elements in the array. 6. Input 0 to quit. Note: In each case, the appropriate selection should call a separate function to execute the specified task. Use a switch statement to implement this. In all cases, uses appropriate and meaningful message prompts for input and use text that fully explains your output, for example for option 5, “The sum of all elements in the array is XXX”. Important!!! Your program should not terminate until a 0 is input to quit!!!
Docsity logo



Copyright © 2024 Ladybird Srl - Via Leonardo da Vinci 16, 10126, Torino, Italy - VAT 10816460017 - All rights reserved