Skip to content

Commit

Permalink
Update readme snippet
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanjermakov committed Mar 18, 2024
1 parent d8c5776 commit 623102b
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,13 @@ pub fn main() {
Shape::Rect(width: 4., height: 2.),
Shape::Circle(radius: 12.34),
]
println(shapes.iter().map(Area::area).collect<List<_>>())
println(
shapes
.iter()
.map(|s| { s.area() })
.collect<List<_>>()
.show()
)
}
```

Expand Down

0 comments on commit 623102b

Please sign in to comment.