summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKunoiSayami <[email protected]>2023-05-10 00:46:28 +0800
committerKunoiSayami <[email protected]>2023-05-10 00:46:28 +0800
commit4ecb5d161c8eecafda5af12becaae8dbfba47c17 (patch)
tree624d980d717f9f12460b77ab6513784834e94a7b
parent901db91584ceb50a5c3f2a1c06620035a064cb01 (diff)
feat: Support show data generate status
Signed-off-by: KunoiSayami <[email protected]>
-rw-r--r--normal_distribution.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/normal_distribution.cpp b/normal_distribution.cpp
index e9c646f..93aff27 100644
--- a/normal_distribution.cpp
+++ b/normal_distribution.cpp
@@ -72,9 +72,12 @@ int main(int argc, char const *argv[]) {
auto ret = set.insert(element);
if (ret.second) {
vector.push_back(element);
- // printf("%lld\n", element);
+
+ fprintf(stderr, "\rProgress %.02f%% %lu",
+ (double)set.size() * 100 / (double)length, set.size());
}
}
+ fputs("", stderr);
assert(vector.size() == length);