Which programming language is this?
@propertyWrapper
struct Clamped {
private var value = 0
var wrappedValue: Int {
get { value }
set { value = min(max(newValue, 0), 100) }
}
}
Answer: Swift
The
Play Programming Languages ▸
@propertyWrapper attribute with a wrappedValue property and the implicit newValue setter parameter are Swift.