Skip to content

Latest commit

 

History

History
22 lines (21 loc) · 2.19 KB

README.md

File metadata and controls

22 lines (21 loc) · 2.19 KB

Programming exercises done as a part of a course on Computer Architecture. Some of these programming exercises come from labsheets done over the semester, while others are random practice problems found online. Organised alphabetically, this list explains what each MIPS code file does.

  • add_subtract: Input two numbers and display their sum and difference
  • bubble_sort: implement bubble sort using a given C code as template. [incomplete]
  • capillary_raise: Given the value of Sigma, Gamma and the cosine of angle between the glass and water, calculate the height of the capillary rise in the tube. Calculations done using formula: H = (2 * σ * cosx) / (γ * R), where we assume σ =5.670373, γ= 9.807
  • factorial: Calculate the factorial of inputted number iteratively.
  • factorial_recursive: Implement a recursive factorial function.
  • fp_io: basic floating point arithmetic and manipulation.
  • hello_world: Print hello world, input an integer and print it back onto console.
  • max_min: Find Minimum and maximum values of array.
  • mul_div_fp: multiply and divide numbers.
  • odd_even: check if integer is even or odd.
  • palindrome: check is user inputted string is palindrome
  • print_array: print an array to console.
  • print_multiples: Write MIPS Assembly code to print all the multiples of the given number between 0 and 100. Your program should allow the user to give the input number.
  • print_fibonacci: Write a recursive MIPS assembly program to print the nth number of Fibonacci sequence.
  • print_pyramid: Print a pyramid of height 'n' (user input)
  • print_shapes: Write a program that asks if the user wants a triangle or a square. It then asks the user for the size of the object (the number of lines it takes to draw the object). The program then writes a triangle or a square of stars to the console.
  • remove_vowels: Write a function to count the number of vowels in a given string and also return the string after removing the vowels and print that string in main function.
  • reverse_string: reverse a user inputted string in place and print it
  • string_length: find length of string stored in data segment.
  • test: disassembly exercises.