bin/main.rb
def player1_prompt
    puts "\nPlayer 1, Please Enter your name: \n"
    @player1 = gets.chomp
    if name_valid?(@player1)
      @player1 = @player1.capitalize.cyan
      puts "#{@player1}, you use X as your symbol"
    else
      puts 'Enter a valid name. Name is String an 3-8 letters long'
      player1_prompt
    end
  end
# Receive the names of players and assign their symbols to identify their play
Receive the names of players and assign their symbols to identify their play
Receive the names of players and assign their symbols to identify their play
def player1_prompt
    puts "\nPlayer 1, Please Enter your name: \n"
    @player1 = gets.chomp
    if name_valid?(@player1)
      @player1 = @player1.capitalize.cyan
      puts "#{@player1}, you use X as your symbol"
    else
      puts 'Enter a valid name. Name is String an 3-8 letters long'
      player1_prompt
    end
  end
def player1_prompt puts "\nPlayer 1, Please Enter your name: \n" @player1 = gets . chomp if name_valid? ( @player1 ) @player1 = @player1 . capitalize . cyan puts "#{@player1}, you use X as your symbol" else puts 'Enter a valid name. Name is String an 3-8 letters long' player1_prompt end end
Receive the names of players and assign their symbols to identify their play
Receive the names of players and assign their symbols to identify their play