std::seed_seq::param(3)
π std::seed_seq::param(3) β C++ Standard Libary π
Hiii bestie, welcome to the std::seed_seq::param(3) page, manual name C++ Standard Libary and all. We're about to get into std::seed_seq::param, and honestly it's giving niche-but-useful. π
πΈ NAME πΈ
std::seed_seq::param β std::seed_seq::param. Yes, that's the name, no cap. It outputs the initial seed sequence stored in the std::seed_seq object. β¨
β¨ Synopsis β¨
template< class OutputIt > (since C++11)
void param( OutputIt dest ) const;
Okay so this outputs the initial seed sequence that's stored in the std::seed_seq object. That's the main-character job. π
π¦ Parameters π¦
destβ an output iterator such that the expression*dest = rtis valid for a valuertofresult_type. Sodesthas to be that exact kind of iterator, bestie. π«Ά
π Type requirements π
OutputItmust meet the requirements ofLegacyOutputIterator. That's the rule, periodt. π
π Return value π
(none) β nothing, nada, zero return value. The function is giving "I do the side effect and leave" energy. π
π₯ Exceptions π₯
It throws only if an operation on dest throws. That's it, that's the whole exception situation. If dest is chill, we're chill. π
π Example π
// Run this code
#include <iostream>
#include <iterator>
#include <random>
int main()
{
std::seed_seq s1 = {-1, 0, 1};
s1.param(std::ostream_iterator<int>(std::cout, " "));
}
β Output β
-1 0 1
The output is literally -1 0 1, slay. π
π cute sign-off: source/version/date is http://cppreference.com, 2024.06.10, and this iconic page is std::seed_seq::param(3) β mwah, bye bestie! π
π¦ where this page comes from
- nixpkgs unstable: stdman 2024.07.05
- opensuse-leap 16.0: stdman 2024.07.05-bp160.1.9 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms