Beginner Rust
Q34 / 100

What is an impl block?

Correct! Well done.

Incorrect.

The correct answer is B) A block defining methods and associated functions for a struct or enum

B

Correct Answer

A block defining methods and associated functions for a struct or enum

Explanation

impl Point { fn new(x: f64, y: f64) -> Self { ... } fn distance(&self) -> f64 { ... } } defines methods on Point.

Progress
34/100