xtd
0.2.0
Loading...
Searching...
No Matches
enumerable_range.cpp
Shows how to use
xtd::linq::enumerable::range
method.
#include <xtd/xtd>
auto
main() ->
int
{
const
auto
& squares = enumerable::range(1, 10).select([](
int
x) {
return
x * x;});
for
(
auto
num : squares)
console::write_line(num);
}
// This code produces the following output :
//
// 1
// 4
// 9
// 16
// 25
// 36
// 49
// 64
// 81
// 100
Generated on Fri Dec 12 2025 12:14:49 for xtd by
Gammasoft
. All rights reserved.