From 262ea101adf94691d76c9a2a34fd07b0fff13af5 Mon Sep 17 00:00:00 2001 From: Jiahan Xie <765130715@qq.com> Date: Thu, 31 Aug 2023 18:55:18 -0400 Subject: [PATCH] replace underscore with dash for my bril program's name, to be coherent with others; mention major-elm in the docs --- benchmarks/mem/{major_elm.bril => major-elm.bril} | 0 benchmarks/mem/{major_elm.out => major-elm.out} | 0 benchmarks/mem/{major_elm.prof => major-elm.prof} | 0 docs/tools/bench.md | 1 + 4 files changed, 1 insertion(+) rename benchmarks/mem/{major_elm.bril => major-elm.bril} (100%) rename benchmarks/mem/{major_elm.out => major-elm.out} (100%) rename benchmarks/mem/{major_elm.prof => major-elm.prof} (100%) diff --git a/benchmarks/mem/major_elm.bril b/benchmarks/mem/major-elm.bril similarity index 100% rename from benchmarks/mem/major_elm.bril rename to benchmarks/mem/major-elm.bril diff --git a/benchmarks/mem/major_elm.out b/benchmarks/mem/major-elm.out similarity index 100% rename from benchmarks/mem/major_elm.out rename to benchmarks/mem/major-elm.out diff --git a/benchmarks/mem/major_elm.prof b/benchmarks/mem/major-elm.prof similarity index 100% rename from benchmarks/mem/major_elm.prof rename to benchmarks/mem/major-elm.prof diff --git a/docs/tools/bench.md b/docs/tools/bench.md index bbce89d1f..73fb1927e 100644 --- a/docs/tools/bench.md +++ b/docs/tools/bench.md @@ -34,6 +34,7 @@ The current benchmarks are: * `gcd`: Calculate Greatest Common Divisor (GCD) of two input positive integer using [Euclidean algorithm][euclidean_into]. * `hanoi`: Print the solution to the *n*-disk [Tower of Hanoi][hanoi] puzzle. * `loopfact`: Compute *n!* imperatively using a loop. +* `major-elm`: Find the majority element in an array using [a linear time voting algorithm](https://www.cs.utexas.edu/~moore/best-ideas/mjrty/). * `mandelbrot`: Generates a really low resolution, ascii, [mandelbrot set][mandelbrot]. * `mat-inv` : Calculates the inverse of a 3x3 matrix and prints it out. * `mat-mul`: Multiplies two `nxn` matrices using the [naive][matmul] matrix multiplication algorithm. The matrices are randomly generated using a [linear congruential generator][rng].