This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <pthread.h> | |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <sys/types.h> | |
| /* the list of integers */ | |
| int *list; | |
| /* the threads will set these values */ | |
| double average; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Program that masks page number and offset from an | |
| * unsigned 32-bit address. | |
| * The size of a page is 4 KB = 4096 Bytes(4096 = 2^12 and so n = 12 bits) | |
| * A memory reference appears as: | |
| * |-----------|-----| | |
| * 31 12 11 0 | |
| */ | |
| #include <stdio.h> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| Evan Wieland | |
| 12/7/2022 | |
| Usage: | |
| $ node dfs-hill-climb.js | |
| > Would you like to run the tests or supply your own graph (y/n)? | |
| > n |
OlderNewer