How To Install bc on Fedora 36

In this tutorial we learn how to install bc in Fedora 36. bc is GNU’s bc (a numeric processing language) and dc (a calculator)

Introduction

In this tutorial we learn how to install bc on Fedora 36.

What is bc

The bc package includes bc and dc. Bc is an arbitrary precision numeric processing arithmetic language. Dc is an interactive arbitrary precision stack based calculator, which can be used as a text mode calculator. Install the bc package if you need its number handling capabilities or if you would like to use its text mode calculator.

We can use yum or dnf to install bc on Fedora 36. In this tutorial we discuss both methods but you only need to choose one of method to install bc.

Install bc on Fedora 36 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

After updating yum database, We can install bc using dnf by running the following command:

sudo dnf -y install bc

Install bc on Fedora 36 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

After updating yum database, We can install bc using yum by running the following command:

sudo yum -y install bc

How To Uninstall bc on Fedora 36

To uninstall only the bc package we can use the following command:

sudo dnf remove bc

bc Package Contents on Fedora 36

/usr/bin/bc
/usr/bin/dc
/usr/lib/.build-id
/usr/lib/.build-id/7b
/usr/lib/.build-id/7b/24b49d6c1dd38f2c7d6825aaaeabc904119719
/usr/lib/.build-id/8d
/usr/lib/.build-id/8d/1a600872f645ab3e063872d41ccb1484321905
/usr/share/doc/bc
/usr/share/doc/bc/AUTHORS
/usr/share/doc/bc/Examples
/usr/share/doc/bc/Examples/ckbook.b
/usr/share/doc/bc/Examples/pi.b
/usr/share/doc/bc/Examples/primes.b
/usr/share/doc/bc/Examples/twins.b
/usr/share/doc/bc/FAQ
/usr/share/doc/bc/NEWS
/usr/share/doc/bc/README
/usr/share/info/bc.info.gz
/usr/share/info/dc.info.gz
/usr/share/licenses/bc
/usr/share/licenses/bc/COPYING
/usr/share/licenses/bc/COPYING.LIB
/usr/share/man/man1/bc.1.gz
/usr/share/man/man1/dc.1.gz

References

Summary

In this tutorial we learn how to install bc on Fedora 36 using yum and [dnf]((/fedora/36/dnf/).