| Last change
 on this file since 3326 was             2615, checked in by cmv, 21 years ago | 
        
          | 
using namespace sophya enleve de machdefs.h, nouveau sopnamsp.h  cmv 10/09/2004
 | 
        
          | File size:
            682 bytes | 
      
      
| Line |  | 
|---|
| 1 | #include <stdio.h> | 
|---|
| 2 | #include <stdlib.h> | 
|---|
| 3 | #include <math.h> | 
|---|
| 4 | #include <iostream> | 
|---|
| 5 |  | 
|---|
| 6 | #include "sopnamsp.h" | 
|---|
| 7 | #include "ppersist.h" | 
|---|
| 8 | int main(int narg, char *arg[]) | 
|---|
| 9 | { | 
|---|
| 10 | char * sid[3] = { "Hello","Reza","ERIC" } ; | 
|---|
| 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]); | 
|---|
| 19 | printf(" Resultat de Hash sur %s = %lx  (%ld) \n", sid[k], code[k], code[k]); | 
|---|
| 20 | cout << " Result--- " << code[k] << endl; | 
|---|
| 21 | } | 
|---|
| 22 | } | 
|---|
       
      
  Note:
 See   
TracBrowser
 for help on using the repository browser.