---
title: "init(format:lenient:)"
framework: foundation
role: symbol
role_heading: Initializer
path: "foundation/integerparsestrategy/init(format:lenient:)-124xn"
---

# init(format:lenient:)

Creates a parse strategy instance using the specified integer format style.

## Declaration

```swift
init<Value>(format: Format, lenient: Bool = true) where Format == IntegerFormatStyle<Value>, Value : BinaryInteger
```

## Parameters

- `format`: A configured doc://com.apple.foundation/documentation/Foundation/IntegerFormatStyle that describes the string format to parse.
- `lenient`: A Boolean value that indicates whether the parse strategy should permit some discrepencies when parsing. Defaults to true.

## See Also

### Creating an integer parse strategy

- [init(format:lenient:)](foundation/integerparsestrategy/init(format:lenient:)-7tox3.md)
- [init(format:lenient:)](foundation/integerparsestrategy/init(format:lenient:)-3gbvo.md)
