Skip to content

GeorgiyIshchenko/long-float

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LongFloat

LongFloat is a C++ library for dealing with arbitrary-precision float arithmetic.

Installation

Use Git to install LongFloat.

git clone 'https://github.com/GeorgiyIshchenko/LongFloat'

Usage

#include <iostream>

#include <LongFloat.h>

using namespace LongNums;

int main() {
    LongFloat a("1.15");
    LongFloat b("2.3");
    std::cout << -a << std::endl;
    std::cout << a * b << std::endl;
    std::cout << a + b << std::endl;
    std::cout << a - b << std::endl;
    std::cout << b / a << std::endl;
    std::cout << "123"_LF / "345"_LF << std::endl;
    return 0;
}

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

About

Library for Arbitrary-precision arithmetic | C++

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published