lib/monkey/lexer.rb
def read_identifier
      position = @position
      read_char while @ch =~ /[a-zA-Z_]/
      @input[position...@position]
    end
# Initialize the lexer with the given input.
#
# @param input [String] the text that will be lexed
Initialize the lexer with the given input.
Initialize the lexer with the given input .
def read_identifier
      position = @position
      read_char while @ch =~ /[a-zA-Z_]/
      @input[position...@position]
    end
def read_identifier position = @position read_char while @ch =~ / [a-zA-Z_] / @input [ position ... @position ] end
Initialize the lexer with the given input.
Initialize the lexer with the given input .
input
the text that will be lexed
the text that will be lexed