Exerpad
🔥0
0 XP
Lv.1 Beginner
Log In

Where Clause

Rewrite this function using a where clause instead of inline trait bounds. The function should compare two values and print which is smaller.

Expected output:

text
Smaller: 3

Hints:

  • Move the bounds from <T: ...> to where T: PartialOrd + std::fmt::Display
  • The where clause goes after the parameter list, before the {
rust
fn main() {
}