std::expone...tion::param(3)

πŸ“¦ version 2024.07.05, in nixpkgs unstable, opensuse-leap 16.0

πŸ’… std::expone...tion::param(3) β€” C++ Standard Libary

okay bestie, gather round, because today's episode of "the C++ standard library is a vibe" is about std::exponential_distribution::param β€” yes that's the full name, the manpage header literally truncates it to std::expone...tion::param(3) because even the doc generator ran out of breath πŸ’€

This one lives in the C++ Standard Libary (that spelling is straight from the source, not me, I would never πŸ™ˆ) and it's basically the little handler that Manages the associated distribution parameter set. Iconic. Low maintenance. Does exactly one job and does it well.


✨ Synopsis ✨

param_type param() const;               (1) (since C++11)
void param( const param_type& params ); (2) (since C++11)

So the way this works, bestie: it Manages the associated distribution parameter set. That's the whole job description and honestly? Respect. 🫢

Two flavors, both since C++11 so they've been here since literally forever in C++ years:

  1. Returns the associated parameter set. Just hands it to you. No drama, no side effects, pure vibes ✨
  2. Sets the associated parameter set to params. New contents, who dis πŸ’…
Not me having to say this: the getter is const, the setter takes const param_type&. Character for character, bestie β€” don't "fix" it.

🌸 Parameters 🌸

  • params β€” new contents of the associated parameter set. That's it. That's the whole parameter list. She's a simple girlie πŸŽ€

πŸ’– Return value πŸ’–

  1. The associated parameter set. (a whole parameter set, handed to you, no cap πŸ‘‘)
  2. (none) β€” the setter returns nothing, it's giving strong silent type energy 🌈

⭐ Complexity ⭐

Constant. literally constant. O(1) queen β€” she does not scale with your input size and she is NOT sorry πŸ¦‹


real talk though: this manpage is short because the function is short, so there's genuinely nothing hiding in here. What you see is what you get, fr fr πŸ’œ

and that's the tea πŸ“ β€” page std::expone...tion::param(3), from the fine folks at http://cppreference.com, dated 2024.06.10. go forth and manage your parameter sets, bestie, i believe in you πŸ˜­πŸ’–

πŸ“¦ where this page comes from