Skip to content

TYSON-Alii/random

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 

Repository files navigation

random

Python random library for c++

#include <iostream>
#include "random.hpp"

int main() {
	auto& r = random; // aliasing
	r.randInt(5, 10);
	random.randFloat();
	if (random.randBool())
		cout << random.rand<unsigned long long>(50) << '\n';
	random.choice({9,3,54,8});
	random.choice({"elma", "armut", "cilek", "yarak"});
	string falanke = "filanke";
	random.choice(falanke);
	// or random.choice("filanke"s);
	random.randRange(50, 10);
	cout << random.randChar() << '\n';
	cout << random.randLetter() << '\n';
	cout << random.randSymbol() << '\n';
};

About

Python random library for c++

Topics

Resources

Stars

Watchers

Forks

Languages