Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integer is class in Ruby #1576

Merged
merged 1 commit into from
Sep 22, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions exercises/concept/chess-game/.docs/hints.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@
## 1. Define rank & file range

- You need to define two [constant][constants] that should hold a [`Range`][range] of ranks and files.
- The ranks should be an [`Int`][integers] `range` from 1 to 8.
- The ranks should be an [`Integer`][integers] `range` from 1 to 8.
- The files should be a [`String`][string] `Range` from 'A' to 'H'.
- The constant needs to be defined in the `Chess` [module][module].

## 2. Check if square is valid

- You need to check if a value is within a range.
- There is [a method][include] that can be used to check if a value is within a range.
- There is [a method][include] that can be used to check if a value is within a range.

## 3. Get player's nickname

Expand Down
2 changes: 1 addition & 1 deletion exercises/concept/chess-game/.docs/instructions.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ Chess::Files
The game will have to check if a square is valid.
A square is valid if the rank and file are within the ranges of the ranks and files.

Define the `Chess.valid_square?` method that takes the arguments `rank` that holds an int of the rank and `file` that holds a char of the file.
Define the `Chess.valid_square?` method that takes the arguments `rank` that holds an integer of the rank and `file` that holds a char of the file.
The method should return `true` if the rank and file are within the ranges of the ranks and files and return `false` otherwise.

```ruby
Expand Down
2 changes: 1 addition & 1 deletion exercises/concept/chess-game/.docs/introduction.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Ranges

[Ranges][range] represent an interval between two values.
The most common types that support ranges are `Int` and `String`.
The most common types that support ranges are `Integer` and `String`.
They can be used for many things like quickly creating a collection, slicing strings, checking if a value is in a range, and iteration.
They are created using the range operator `..` or `...` (inclusive and exclusive, respectively).

Expand Down