source: Sophya/trunk/SophyaProg/Tests/thash.cc@ 3606

Last change on this file since 3606 was 3572, checked in by cmv, 17 years ago

char* -> const char* pour regler les problemes de deprecated string const... + comparaison unsigned signed + suppression EVOL_PLANCK rz+cmv 07/02/2009

File size: 688 bytes
RevLine 
[1170]1#include <stdio.h>
2#include <stdlib.h>
3#include <math.h>
[2322]4#include <iostream>
[1170]5
[2615]6#include "sopnamsp.h"
[1170]7#include "ppersist.h"
8int main(int narg, char *arg[])
9{
[3572]10 const char * sid[3] = { "Hello","Reza","ERIC" } ;
[1170]11 uint_8 code[3];
12 int k;
13 printf(" ------- Testing SOPHYA Hash coding --------- \n");
14 printf(" Size of uint_4 = %d \n ", sizeof(uint_4));
15 printf(" Size of uint_8 = %d \n ", sizeof(uint_8));
16 printf(" Size of unsigned long = %d \n ", sizeof(unsigned long));
17 for(k=0; k<3; k++) {
18 code[k] = PPersistRegistrar<double>::Hash(sid[k]);
[1171]19 printf(" Resultat de Hash sur %s = %lx (%ld) \n", sid[k], code[k], code[k]);
[1170]20 cout << " Result--- " << code[k] << endl;
21 }
22}
Note: See TracBrowser for help on using the repository browser.