https://github.com/jmkoni/katabankocr
http://codingdojo.org/kata/BankOCR/
https://github.com/jmkoni/katabankocr
Last synced: 11 months ago
JSON representation
http://codingdojo.org/kata/BankOCR/
- Host: GitHub
- URL: https://github.com/jmkoni/katabankocr
- Owner: jmkoni
- Created: 2017-09-28T12:54:13.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-10-04T19:36:39.000Z (over 8 years ago)
- Last Synced: 2025-04-08T22:32:42.472Z (about 1 year ago)
- Language: Ruby
- Size: 80.1 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# KataBankOCR
This is an attempt to solve the KataBankOCR problem, user stories 1 through 3.
View original problem at: http://codingdojo.org/kata/BankOCR/
View full docs at: https://jmkoni.github.io/KataBankOCR/
View source code at: https://github.com/jmkoni/KataBankOCR
#### Initialization:
```ruby
PipeNumber::Reader.new(filepath)
```
#### Definition of parameters:
* filepath: path to file containing text numbers
#### Example:
Of running the class:
```ruby
# numbers.txt looks like this:
# _ _ _ _ _ _ _
# | _| _||_||_ |_ ||_||_|
# ||_ _| | _||_| ||_| _|
#
# _ _ _ _ _ _ _ _
# | || || || || || || ||_ |
# |_||_||_||_||_||_||_| _| |
#
# _ _ _ _ _ _ _
# |_||_|| || ||_ | | | _
# | _||_||_||_| | | | _|
reader = PipeNumber::Reader.new("~/Desktop/numbers.txt")
reader.print_all_with_variations
```
Of running the script:
```ruby
ruby read_numbers.rb
# it will then prompt you for a file path. Please type it in, then press enter.
```
#### Output:
```
123456789
000000051
49006771? ILL
```