Blame view

SD/TP6_Hachage/hachage_simple.h 484 Bytes
cb716d77   Vincent Benoist   SD jusqua hachage
1
  /* hachage_simple.h */
5be5d85e   Vincent Benoist   tp processus
2
  #include "abr.h"
cb716d77   Vincent Benoist   SD jusqua hachage
3
4
5
  #include <stdbool.h>
  
  struct alveole {
5be5d85e   Vincent Benoist   tp processus
6
      struct abr* L;
cb716d77   Vincent Benoist   SD jusqua hachage
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
  };
  
  typedef int fonction_hachage (double);
  
  #define N 10
  struct table {
      struct alveole tab [N];
      fonction_hachage* hash;
  };
  
  extern void init_table (struct table*, fonction_hachage*);
  extern void clear_table (struct table*);
  extern void enregistrer_table (struct table*, double);
  extern bool rechercher_table (struct table*, double);
  extern void imprimer_table (struct table*);