Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

This is assembly mips program ask to complete the function and follow the output instructions. please complete function in mips code and you can use

image text in transcribed

This is assembly mips program ask to complete the function and follow the output instructions. please complete function in mips code and you can use any main function to test.

F. int createProjection(String str) This function converts a string into a binary projection of the string where each bit corresponds to a specific character of the alphabet. Any non-alphabet characters are ignored. The least significant bit, bit 0, will correspond to 'a' or 'A'. Bit 1 corresponds to 'b' or 'B'. Bit 2 with 'c' and 'C', and so on. The upper 6 bits are not used (always set to 0), since there are only 26 letters in the alphabet. Ifa character has 1+ occurrences in str, the corresponding bit in the binary projection is set to 1. Rest of the alphabet Uppermost 6 bits 000000 fe dcba 0 0 0 1 e b b Function parameter and return value summary: str: starting address of null-terminated ASCII character string of any length returns: the integer value represented by the binary projection of the string | We WILL NOT test the function with an invalid str argument address. | The function MUST NOT modify str. str "EB" "hello!" "aBcdefghijklmnopqrstuvwxyzABC" "a return (integer) return (binary) 18 00000000000000000000000000010010 18576 00000000000000000100100010010000 67108863 00000011111111111111111111111111 1 00000000000000000000000000000001 8 00000000000000000000000000001000 0 00000000000000000000000000000000 "DDDDd" "10" Think about the relationship between the ASCII character on the ASCII chart. How can this information be used to determine the index in the bit representation to set

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Professional IPhone And IPad Database Application Programming

Authors: Patrick Alessi

1st Edition

0470636173, 978-0470636176

More Books

Students also viewed these Databases questions

Question

Question What are the advantages of a written bonus plan?

Answered: 1 week ago