Course Solutions Uncategorized (Solved) : Complete Following Step Using Code Given C Explanation Would Nice 1 Valid Input Mark Grid Q31440845 . . . .

(Solved) : Complete Following Step Using Code Given C Explanation Would Nice 1 Valid Input Mark Grid Q31440845 . . . .

 

Complete the following step using the code given:

C#

An explanation would be nice too.

#1. When you have a valid input mark the grid location as usedand then render an X in the square to indicate it has been used.The X should be Red if it was a hit on a ship.

#—#   #—#
| X |   | X |
#—#   #—#

using System;

using System.Collections.Generic;

using System.Linq;

using System.Text;

using System.Threading.Tasks;

class Program

{

    static void Main(string[] args)

    {

        while (true)

        {//Users enterguess

           printGrid(Grid);

           Console.WriteLine(“Type ‘exit’ to exit.”);

           Console.WriteLine(“Enter your guess: “);

           string cons = Console.ReadLine();

           cons.Substring(0, 1);

           cons.Substring(1, 1);

           cons = cons.ToUpper();

           char column = cons[0];

           char row = cons[1];

           int num = cons[0];

           bool result = Int32.TryParse(cons, out num);

           //Valid Charaters

           string

OR

PayPal Gateway not configured

OR

PayPal Gateway not configured

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post