COIN-OR::LEMON - Graph Library

Ignore:
Timestamp:
10/14/06 17:26:05 (14 years ago)
Author:
Balazs Dezso
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@2991
Message:

New random interface
Switching to the new interface

File:
1 edited

Legend:

Unmodified
Added
Removed
  • benchmark/radix_sort-bench.cc

    r1956 r2242  
    2727#include <lemon/radix_sort.h>
    2828
     29#include <lemon/random.h>
     30
    2931#include <vector>
    3032#include <algorithm>
     
    3840  vector<int> data(n);
    3941  for (int i = 0; i < n; ++i) {
    40     data[i] = (int)(1000 * (rand() / (RAND_MAX + 1.0))) - 500;
     42    data[i] = rnd[1000] - 500;
    4143  }
    4244  radixSort(data.begin(), data.end());
     
    4850  vector<int> data(n);
    4951  for (int i = 0; i < n; ++i) {
    50     data[i] = (int)(1000 * (rand() / (RAND_MAX + 1.0))) - 500;
     52    data[i] = rnd[1000] - 500;
    5153  }
    5254  counterSort(data.begin(), data.end());
     
    5759  vector<int> data(n);
    5860  for (int i = 0; i < n; ++i) {
    59     data[i] = (int)(1000 * (rand() / (RAND_MAX + 1.0))) - 500;
     61    data[i] = rnd[1000] - 500;
    6062  }
    6163  sort(data.begin(), data.end());
     
    6668  vector<int> data(n);
    6769  for (int i = 0; i < n; ++i) {
    68     data[i] = (int)(1000 * (rand() / (RAND_MAX + 1.0))) - 500;
     70    data[i] = rnd[1000] - 500;
    6971  }
    7072  stable_sort(data.begin(), data.end());
Note: See TracChangeset for help on using the changeset viewer.