Keshav Malik Keshav Malik
using System;
namespace viden {
  
class GFG {
  
    // Main Method
    public static void Main()
    {
  
        // declares a 1D Array of string.
        string[] weekDays;
  
        // allocating memory for days.
        weekDays = new string[] {"Sun", "Mon", "Tue", "Wed",
                                       "Thu", "Fri", "Sat"};
  
        // Displaying Elements of the array
        foreach(string day in weekDays)
            Console.Write(day + " ");
  
        Console.Write("\nTotal Number of Elements: ");
  
        // using Length property
        Console.Write(weekDays.Length);
    }
}
}
Keshav Malik

Keshav Malik Creator

(No description available)

Suggested Creators

Keshav Malik