mirror of
https://github.com/Comp211-SP24/lab-03-Rushilwiz.git
synced 2025-04-09 22:00:17 -04:00
39 lines
916 B
C
39 lines
916 B
C
// PID: 9DigitPidNoSpacesOrDashes
|
|
// I pledge the COMP 211 honor code.
|
|
|
|
/**
|
|
* DO NOT define a main function in this file!
|
|
* This file is intended to be a library file, so a main function here
|
|
* will conflict with the main function in test.c (our "runner" file)
|
|
* To test your functions, write tests in test.c
|
|
*/
|
|
|
|
#include "bit_utils.h"
|
|
|
|
unsigned int mask(unsigned int num, unsigned int bits) {
|
|
// TODO: implement
|
|
return 0;
|
|
}
|
|
|
|
unsigned int set(unsigned int num, unsigned int bits) {
|
|
// TODO: implement
|
|
return 0;
|
|
}
|
|
|
|
unsigned int inverse(unsigned int num, unsigned int bits) {
|
|
// TODO: implement
|
|
return 0;
|
|
}
|
|
|
|
unsigned int bit_select(unsigned int num,
|
|
unsigned int startbit,
|
|
unsigned int endbit) {
|
|
// TODO: implement
|
|
return 0;
|
|
}
|
|
|
|
unsigned int barrel_shift(unsigned int num, unsigned int shamt) {
|
|
// TODO: implement
|
|
return 0;
|
|
}
|