Advertisement
Guest User

Untitled

a guest
May 29th, 2015
266
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.76 KB | None | 0 0
  1. int main (int argc, const char * argv[]) {
  2.     const char* filename;
  3.     struct hashMap *hashTable; 
  4.     int tableSize = 10;
  5.     clock_t timer;
  6.     FILE *fileptr; 
  7.     /*
  8.      this part is using command line arguments, you can use them if you wish
  9.      but it is not required. DO NOT remove this code though, we will use it for
  10.      testing your program.
  11.      
  12.      if you wish not to use command line arguments manually type in your
  13.      filename and path in the else case.
  14.      */
  15.     if(argc == 2)
  16.         filename = argv[1];
  17.     else
  18.         filename = "input2.txt"; /*specify your input text file here*/
  19.    
  20.     printf("opening file: %s\n", filename);
  21.    
  22.     timer = clock();
  23.    
  24.     hashTable = createMap(tableSize);      
  25.    
  26.     /*... concordance code goes here ...*/
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement